Skip to content

Commit

Permalink
Merge pull request #18 from jrhubott/device-sort
Browse files Browse the repository at this point in the history
Sort by device
  • Loading branch information
EuleMitKeule authored Sep 22, 2024
2 parents b7ceedb + e14fa32 commit 25fe54d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion custom_components/device_tools/config_flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ async def async_step_user(
or device.id,
}
)
for device in self.device_registry.devices.values()
for device in sorted(list(self.device_registry.devices.values()),key=lambda x: x.name_by_user or x.name or x.id)
if device.id not in other_device_ids
and device.disabled_by is None
],
Expand Down

0 comments on commit 25fe54d

Please sign in to comment.