Fix app name sorting in apple_tv (#109274)

This commit is contained in:
J. Nick Koston 2024-01-31 21:53:18 -10:00 committed by GitHub
parent 723d9c4c8a
commit 5d3364521f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -155,7 +155,7 @@ class AppleTvMediaPlayer(AppleTVEntity, MediaPlayerEntity):
else:
self._app_list = {
app_name: app.identifier
for app in sorted(apps, key=lambda app: app_name.lower())
for app in sorted(apps, key=lambda app: (app.name or "").lower())
if (app_name := app.name) is not None
}
self.async_write_ha_state()