mirror of
https://github.com/home-assistant/core.git
synced 2025-08-10 16:15:08 +02:00
make sure device info is linked up at startup
This commit is contained in:
@@ -155,6 +155,11 @@ class DlnaDmrEntity(MediaPlayerEntity):
|
|||||||
self.browse_unfiltered = browse_unfiltered
|
self.browse_unfiltered = browse_unfiltered
|
||||||
self._device_lock = asyncio.Lock()
|
self._device_lock = asyncio.Lock()
|
||||||
self._background_setup_task: asyncio.Task[None] | None = None
|
self._background_setup_task: asyncio.Task[None] | None = None
|
||||||
|
# Device info will be updated when the device is connected
|
||||||
|
self._attr_device_info = dr.DeviceInfo(
|
||||||
|
connections={(dr.CONNECTION_UPNP, self.udn)},
|
||||||
|
default_name=name,
|
||||||
|
)
|
||||||
|
|
||||||
async def async_added_to_hass(self) -> None:
|
async def async_added_to_hass(self) -> None:
|
||||||
"""Handle addition."""
|
"""Handle addition."""
|
||||||
|
Reference in New Issue
Block a user