mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 11:17:21 +00:00
Fix switch light adding itself to devices (#68060)
This commit is contained in:
parent
ea6da674df
commit
a902f0ee53
@ -113,4 +113,5 @@ class LightSwitch(LightEntity):
|
||||
|
||||
# Add this entity to the wrapped switch's device
|
||||
registry = er.async_get(self.hass)
|
||||
if registry.async_get(self.entity_id) is not None:
|
||||
registry.async_update_entity(self.entity_id, device_id=self._device_id)
|
||||
|
Loading…
x
Reference in New Issue
Block a user