fix mqtt sensor

This commit is contained in:
Andrey
2021-01-28 12:04:43 +03:00
parent c36c1369aa
commit 3b6459468b
2 changed files with 3 additions and 3 deletions

View File

@@ -160,7 +160,7 @@ async def async_remove_entry(hass, entry) -> None:
if hub is None:
return
_LOGGER.debug(f'remove {id}')
_hubs.pop(entry.entry_id)
_hubs.pop(id, None)
task: asyncio.Task = _POLL_TASKS.pop(id, None)
if task is not None:
task.cancel()