From f6c5e5ff00582917f6af88a67db50ac77c9cc978 Mon Sep 17 00:00:00 2001 From: Tom Harris Date: Tue, 22 Aug 2017 03:22:37 -0400 Subject: [PATCH] Added insteonplm device_override multiple capabilities (#9078) --- .gitignore | 3 +++ homeassistant/components/insteon_plm.py | 8 ++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 26efcc25b85..87bc6990ce4 100644 --- a/.gitignore +++ b/.gitignore @@ -94,3 +94,6 @@ docs/build # Windows Explorer desktop.ini +/home-assistant.pyproj +/home-assistant.sln +/.vs/home-assistant/v14 diff --git a/homeassistant/components/insteon_plm.py b/homeassistant/components/insteon_plm.py index 7cadbd0dd7f..92807bf9b1c 100644 --- a/homeassistant/components/insteon_plm.py +++ b/homeassistant/components/insteon_plm.py @@ -79,8 +79,12 @@ def async_setup(hass, config): # # Override the device default capabilities for a specific address # - plm.protocol.devices.add_override( - device['address'], 'capabilities', [device['platform']]) + if isinstance(device['platform'], list): + plm.protocol.devices.add_override( + device['address'], 'capabilities', device['platform']) + else: + plm.protocol.devices.add_override( + device['address'], 'capabilities', [device['platform']]) hass.data['insteon_plm'] = plm