mirror of
https://github.com/home-assistant/core.git
synced 2025-08-12 09:05:15 +02:00
Change discovered from a list of dict to a dict
This commit is contained in:
@@ -27,10 +27,9 @@ def async_setup_platform(hass, config, async_add_devices, discovery_info=None):
|
||||
entities = []
|
||||
plm = hass.data['insteon_plm']
|
||||
|
||||
for device_info in discovery_info:
|
||||
address = device_info['address']
|
||||
address = discovery_info['address']
|
||||
device = plm.devices[address]
|
||||
state_key = device_info['state_key']
|
||||
state_key = discovery_info['state_key']
|
||||
|
||||
entities.append(InsteonPLMBinarySensor(device, state_key))
|
||||
|
||||
|
Reference in New Issue
Block a user