Simplisafe unknown status fix (#9111)

* Simplisafe unknown status fix

Changed simplisafe-python requirement to 1.0.5 and changed state return
case statements to lower case

* Bump requirements_all.txt
This commit is contained in:
lekobob 2017-08-23 23:09:50 -07:00 committed by Fabian Affolter
parent 0dccef4063
commit 698d133455
2 changed files with 5 additions and 5 deletions

View file

@ -16,7 +16,7 @@ from homeassistant.const import (
EVENT_HOMEASSISTANT_STOP)
import homeassistant.helpers.config_validation as cv
REQUIREMENTS = ['simplisafe-python==1.0.4']
REQUIREMENTS = ['simplisafe-python==1.0.5']
_LOGGER = logging.getLogger(__name__)
@ -89,11 +89,11 @@ class SimpliSafeAlarm(alarm.AlarmControlPanel):
def state(self):
"""Return the state of the device."""
status = self.simplisafe.state()
if status == 'Off':
if status == 'off':
state = STATE_ALARM_DISARMED
elif status == 'Home':
elif status == 'home':
state = STATE_ALARM_ARMED_HOME
elif status == 'Away':
elif status == 'away':
state = STATE_ALARM_ARMED_AWAY
else:
state = STATE_UNKNOWN

View file

@ -884,7 +884,7 @@ sharp_aquos_rc==0.3.2
shodan==1.7.4
# homeassistant.components.alarm_control_panel.simplisafe
simplisafe-python==1.0.4
simplisafe-python==1.0.5
# homeassistant.components.notify.slack
slacker==0.9.60