Set Switchbot _attr_is_closed on init (#56611)
* self._attr_is_closed needs to be set initially. * Set _attr_is_closed on init.
This commit is contained in:
parent
8aff51042b
commit
3c80e05100
1 changed files with 1 additions and 0 deletions
|
@ -77,6 +77,7 @@ class SwitchBotCurtainEntity(SwitchbotEntity, CoverEntity, RestoreEntity):
|
||||||
"""Initialize the Switchbot."""
|
"""Initialize the Switchbot."""
|
||||||
super().__init__(coordinator, idx, mac, name)
|
super().__init__(coordinator, idx, mac, name)
|
||||||
self._attr_unique_id = idx
|
self._attr_unique_id = idx
|
||||||
|
self._attr_is_closed = None
|
||||||
self._device = device
|
self._device = device
|
||||||
|
|
||||||
async def async_added_to_hass(self) -> None:
|
async def async_added_to_hass(self) -> None:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue