1
0
mirror of https://github.com/esphome/esphome.git synced 2025-10-30 14:43:51 +00:00

Fix for OTA mode not activating in safe_mode when OTA section has an on_xxxx action (#7796)

Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
This commit is contained in:
Alain Turbide
2024-11-21 15:39:32 -05:00
committed by GitHub
parent ccf2854b61
commit 3232866dc3
2 changed files with 5 additions and 4 deletions

View File

@@ -92,6 +92,7 @@ async def to_code(config):
async def ota_to_code(var, config):
await cg.past_safe_mode()
use_state_callback = False
for conf in config.get(CONF_ON_STATE_CHANGE, []):
trigger = cg.new_Pvariable(conf[CONF_TRIGGER_ID], var)