1
0
mirror of https://github.com/esphome/esphome.git synced 2025-03-14 06:38:17 +00:00

fix: initialize DynamicLampTimer correctly in restore_timers_ method of DynamicLampComponent

This commit is contained in:
Oliver Kleinecke 2025-02-19 20:19:20 +01:00
parent 9701ac6ee1
commit 6112ac1520

View File

@ -403,8 +403,9 @@ void DynamicLampComponent::restore_timers_() {
this->status_set_warning();
break;
case SupportedSaveModes::SAVE_MODE_FRAM:
DynamicLampTimer timer = DynamicLampTimer();
DynamicLampTimer timer;
for (uint8_t i = 0; i < 12; i++) {
timer = DynamicLampTimer();
this->timers_[i] = timer;
this->timers_[i].in_use = false;
}