forked from home-assistant/core
group.setup now fails gracefully if config[group] not available.
This commit is contained in:
@@ -91,7 +91,7 @@ def get_entity_ids(hass, entity_id, domain_filter=None):
|
|||||||
|
|
||||||
def setup(hass, config):
|
def setup(hass, config):
|
||||||
""" Sets up all groups found definded in the configuration. """
|
""" Sets up all groups found definded in the configuration. """
|
||||||
for name, entity_ids in config[DOMAIN].items():
|
for name, entity_ids in config.get(DOMAIN, {}).items():
|
||||||
entity_ids = entity_ids.split(",")
|
entity_ids = entity_ids.split(",")
|
||||||
|
|
||||||
setup_group(hass, name, entity_ids)
|
setup_group(hass, name, entity_ids)
|
||||||
|
Reference in New Issue
Block a user