Use shorthand attributes in Kodi (#99578)
parent
d5ad01ffbe
commit
c49f086790
|
@ -282,7 +282,7 @@ class KodiEntity(MediaPlayerEntity):
|
||||||
"""Initialize the Kodi entity."""
|
"""Initialize the Kodi entity."""
|
||||||
self._connection = connection
|
self._connection = connection
|
||||||
self._kodi = kodi
|
self._kodi = kodi
|
||||||
self._unique_id = uid
|
self._attr_unique_id = uid
|
||||||
self._device_id = None
|
self._device_id = None
|
||||||
self._players = None
|
self._players = None
|
||||||
self._properties = {}
|
self._properties = {}
|
||||||
|
@ -369,11 +369,6 @@ class KodiEntity(MediaPlayerEntity):
|
||||||
if close:
|
if close:
|
||||||
await self._connection.close()
|
await self._connection.close()
|
||||||
|
|
||||||
@property
|
|
||||||
def unique_id(self):
|
|
||||||
"""Return the unique id of the device."""
|
|
||||||
return self._unique_id
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def state(self) -> MediaPlayerState:
|
def state(self) -> MediaPlayerState:
|
||||||
"""Return the state of the device."""
|
"""Return the state of the device."""
|
||||||
|
|
Loading…
Reference in New Issue