Skip to content

Commit

Permalink
Fix unload entry bug
Browse files Browse the repository at this point in the history
Version 1.0.1
  • Loading branch information
bergdahl committed Jul 15, 2024
1 parent f922c9a commit 7408bc0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion custom_components/growcube/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,10 @@ async def async_unload_entry(hass: HomeAssistant, entry: dict):
"""Unload the Growcube entry."""
client = hass.data[DOMAIN][entry.entry_id]
client.disconnect()
return True
unload_ok = await hass.config_entries.async_unload_platforms(entry, PLATFORMS)
if unload_ok:
hass.data[DOMAIN].pop(entry.entry_id)
return unload_ok



Expand Down
2 changes: 1 addition & 1 deletion custom_components/growcube/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@
"requirements": [
"growcube-client==1.2.2"
],
"version": "1.0.0"
"version": "1.0.1"
}

0 comments on commit 7408bc0

Please sign in to comment.