Use list literals (#33659)
This commit is contained in:
1 parent
dde93304d3
commit
db72039b8f
14 files changed
+18
-18
No files matched your search
@@ -195,7 +195,7 @@ def devices_with_push(hass):
|
||||
|
||||
def enabled_push_ids(hass):
|
||||
"""Return a list of push enabled target push IDs."""
|
||||
push_ids = list()
|
||||
push_ids = []
|
||||
for device in hass.data[DOMAIN][ATTR_DEVICES].values():
|
||||
if device.get(ATTR_PUSH_ID) is not None:
|
||||
push_ids.append(device.get(ATTR_PUSH_ID))
|
||||
|
||||
@@ -20,7 +20,7 @@ def setup_platform(hass, config, add_entities, discovery_info=None):
|
||||
|
||||
async def async_setup_entry(hass, config_entry, async_add_entities):
|
||||
"""Set up iOS from a config entry."""
|
||||
dev = list()
|
||||
dev = []
|
||||
for device_name, device in ios.devices(hass).items():
|
||||
for sensor_type in ("level", "state"):
|
||||
dev.append(IOSSensor(sensor_type, device_name, device))
|
||||
|
||||
Reference in new issue
Block a user