diff --git a/custom_components/mega/__init__.py b/custom_components/mega/__init__.py index 3cc45e5..8d7edca 100644 --- a/custom_components/mega/__init__.py +++ b/custom_components/mega/__init__.py @@ -210,7 +210,7 @@ async def async_remove_entry(hass: HomeAssistant, entry: ConfigEntry) -> None: id = entry.data.get('id', entry.entry_id) hub: MegaD = hass.data[DOMAIN].get(id) if hub is None: - return + return True _LOGGER.debug(f'remove {id}') _hubs.pop(id, None) hass.data[DOMAIN].pop(id, None) @@ -221,7 +221,7 @@ async def async_remove_entry(hass: HomeAssistant, entry: ConfigEntry) -> None: if task is not None: task.cancel() if hub is None: - return + return True await hub.stop() return True