Skip to content

Commit 867630a

Browse files
authored
Remove state when entity is removed from registry (#32184)
1 parent a6d5ed0 commit 867630a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

homeassistant/helpers/entity.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -542,6 +542,7 @@ async def _async_registry_updated(self, event):
542542
data = event.data
543543
if data["action"] == "remove" and data["entity_id"] == self.entity_id:
544544
await self.async_removed_from_registry()
545+
await self.async_remove()
545546

546547
if (
547548
data["action"] != "update"

0 commit comments

Comments
 (0)