mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Only validate entity id if it did not exist on state change (#41820)
This commit is contained in:
parent
3cba25a892
commit
afc602595b
@ -1148,7 +1148,15 @@ class StateMachine:
|
|||||||
if context is None:
|
if context is None:
|
||||||
context = Context()
|
context = Context()
|
||||||
|
|
||||||
state = State(entity_id, new_state, attributes, last_changed, None, context)
|
state = State(
|
||||||
|
entity_id,
|
||||||
|
new_state,
|
||||||
|
attributes,
|
||||||
|
last_changed,
|
||||||
|
None,
|
||||||
|
context,
|
||||||
|
old_state is None,
|
||||||
|
)
|
||||||
self._states[entity_id] = state
|
self._states[entity_id] = state
|
||||||
self._bus.async_fire(
|
self._bus.async_fire(
|
||||||
EVENT_STATE_CHANGED,
|
EVENT_STATE_CHANGED,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user