mirror of
https://github.com/home-assistant/core.git
synced 2025-11-09 02:49:40 +00:00
Suppress errors for legacy nest api when using media source (#61629)
This commit is contained in:
@@ -64,6 +64,9 @@ async def async_get_media_source(hass: HomeAssistant) -> MediaSource:
|
||||
|
||||
async def get_media_source_devices(hass: HomeAssistant) -> Mapping[str, Device]:
|
||||
"""Return a mapping of device id to eligible Nest event media devices."""
|
||||
if DATA_SUBSCRIBER not in hass.data[DOMAIN]:
|
||||
# Integration unloaded, or is legacy nest integration
|
||||
return {}
|
||||
subscriber = hass.data[DOMAIN][DATA_SUBSCRIBER]
|
||||
device_manager = await subscriber.async_get_device_manager()
|
||||
device_registry = await hass.helpers.device_registry.async_get_registry()
|
||||
|
||||
Reference in New Issue
Block a user