mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
don't break the chain
This commit is contained in:
parent
8d42e42230
commit
efdd0c9e8a
@ -61,14 +61,13 @@ def reproduce_state(hass, states, blocking=False):
|
||||
service = SERVICE_MEDIA_PAUSE
|
||||
elif state.domain == 'media_player' and state == STATE_PLAYING:
|
||||
service = SERVICE_MEDIA_PLAY
|
||||
else:
|
||||
if state.state == STATE_ON:
|
||||
elif state.state == STATE_ON:
|
||||
service = SERVICE_TURN_ON
|
||||
elif state.state == STATE_OFF:
|
||||
service = SERVICE_TURN_OFF
|
||||
else:
|
||||
_LOGGER.warning("reproduce_state: Unable to reproduce \
|
||||
state %s", state)
|
||||
_LOGGER.warning("reproduce_state: Unable to reproduce state %s",
|
||||
state)
|
||||
continue
|
||||
|
||||
service_data = dict(state.attributes)
|
||||
|
Loading…
x
Reference in New Issue
Block a user