From 4d080f8b17fc37376b8550321dc215c2b67e60bb Mon Sep 17 00:00:00 2001 From: Fredrik Erlandsson Date: Tue, 16 Apr 2019 01:41:33 +0200 Subject: [PATCH] skip non existing zones (#23113) --- homeassistant/components/daikin/switch.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/homeassistant/components/daikin/switch.py b/homeassistant/components/daikin/switch.py index 74d03985478..3106a7e8013 100644 --- a/homeassistant/components/daikin/switch.py +++ b/homeassistant/components/daikin/switch.py @@ -27,7 +27,8 @@ async def async_setup_entry(hass, entry, async_add_entities): if zones: async_add_entities([ DaikinZoneSwitch(daikin_api, zone_id) - for zone_id in range(len(zones)) + for zone_id, name in enumerate(zones) + if name != '-' ])