mirror of
https://github.com/home-assistant/core.git
synced 2025-07-27 07:07:28 +00:00
Do not report state when closing down (#32168)
This commit is contained in:
parent
5488389244
commit
900714a3ee
@ -26,6 +26,9 @@ async def async_enable_proactive_mode(hass, smart_home_config):
|
|||||||
await smart_home_config.async_get_access_token()
|
await smart_home_config.async_get_access_token()
|
||||||
|
|
||||||
async def async_entity_state_listener(changed_entity, old_state, new_state):
|
async def async_entity_state_listener(changed_entity, old_state, new_state):
|
||||||
|
if not hass.is_running:
|
||||||
|
return
|
||||||
|
|
||||||
if not new_state:
|
if not new_state:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
@ -21,6 +21,9 @@ def async_enable_report_state(hass: HomeAssistant, google_config: AbstractConfig
|
|||||||
"""Enable state reporting."""
|
"""Enable state reporting."""
|
||||||
|
|
||||||
async def async_entity_state_listener(changed_entity, old_state, new_state):
|
async def async_entity_state_listener(changed_entity, old_state, new_state):
|
||||||
|
if not hass.is_running:
|
||||||
|
return
|
||||||
|
|
||||||
if not new_state:
|
if not new_state:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user