mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +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:
|
||||
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._bus.async_fire(
|
||||
EVENT_STATE_CHANGED,
|
||||
|
Loading…
x
Reference in New Issue
Block a user