mirror of
https://github.com/home-assistant/core.git
synced 2025-07-31 09:17:10 +00:00
Ignore None state in state_change_event (#59485)
This commit is contained in:
parent
c2f227bf16
commit
9cb4a5ca39
@ -156,6 +156,7 @@ class IntegrationSensor(RestoreEntity, SensorEntity):
|
|||||||
|
|
||||||
if (
|
if (
|
||||||
old_state is None
|
old_state is None
|
||||||
|
or new_state is None
|
||||||
or old_state.state in (STATE_UNKNOWN, STATE_UNAVAILABLE)
|
or old_state.state in (STATE_UNKNOWN, STATE_UNAVAILABLE)
|
||||||
or new_state.state in (STATE_UNKNOWN, STATE_UNAVAILABLE)
|
or new_state.state in (STATE_UNKNOWN, STATE_UNAVAILABLE)
|
||||||
):
|
):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user