mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 04:37:06 +00:00
Migrate AppleTV to use has entity name (#96563)
* Migrate AppleTV to use has entity name * Add comma
This commit is contained in:
parent
38630f7898
commit
a27e126c86
@ -88,14 +88,18 @@ class AppleTVEntity(Entity):
|
||||
"""Device that sends commands to an Apple TV."""
|
||||
|
||||
_attr_should_poll = False
|
||||
_attr_has_entity_name = True
|
||||
_attr_name = None
|
||||
|
||||
def __init__(self, name, identifier, manager):
|
||||
"""Initialize device."""
|
||||
self.atv = None
|
||||
self.manager = manager
|
||||
self._attr_name = name
|
||||
self._attr_unique_id = identifier
|
||||
self._attr_device_info = DeviceInfo(identifiers={(DOMAIN, identifier)})
|
||||
self._attr_device_info = DeviceInfo(
|
||||
identifiers={(DOMAIN, identifier)},
|
||||
name=name,
|
||||
)
|
||||
|
||||
async def async_added_to_hass(self):
|
||||
"""Handle when an entity is about to be added to Home Assistant."""
|
||||
|
Loading…
x
Reference in New Issue
Block a user