From 3625646c34fed4c5081e73c175e257ee426a4c37 Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Wed, 23 Sep 2015 23:35:08 -0700 Subject: [PATCH] Fix reproduce_state --- homeassistant/helpers/state.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/homeassistant/helpers/state.py b/homeassistant/helpers/state.py index 6d4cb36dd4b..909b86a67ed 100644 --- a/homeassistant/helpers/state.py +++ b/homeassistant/helpers/state.py @@ -57,9 +57,9 @@ def reproduce_state(hass, states, blocking=False): state.entity_id) continue - if state.domain == 'media_player' and state == STATE_PAUSED: + if state.domain == 'media_player' and state.state == STATE_PAUSED: service = SERVICE_MEDIA_PAUSE - elif state.domain == 'media_player' and state == STATE_PLAYING: + elif state.domain == 'media_player' and state.state == STATE_PLAYING: service = SERVICE_MEDIA_PLAY elif state.state == STATE_ON: service = SERVICE_TURN_ON