Automation component now supports YAML lists for config key service_entity_id

pull/275/head
theolind 2015-08-24 21:19:47 +02:00
parent 05df84d04f
commit a7889ef628
1 changed files with 6 additions and 2 deletions

View File

@ -62,8 +62,12 @@ def _get_action(hass, config):
service_data = {}
if CONF_SERVICE_ENTITY_ID in config:
service_data[ATTR_ENTITY_ID] = \
config[CONF_SERVICE_ENTITY_ID].split(",")
try:
service_data[ATTR_ENTITY_ID] = \
config[CONF_SERVICE_ENTITY_ID].split(",")
except AttributeError:
service_data[ATTR_ENTITY_ID] = \
config[CONF_SERVICE_ENTITY_ID]
hass.services.call(domain, service, service_data)