mirror of
https://github.com/basnijholt/adaptive-lighting.git
synced 2026-09-11 22:34:04 +02:00
fix setting state before turn_on
This commit is contained in:
parent
f2fcd1aab9
commit
d304b49d53
1 changed files with 0 additions and 1 deletions
|
|
@ -291,7 +291,6 @@ class AdaptiveSwitch(SwitchEntity, RestoreEntity):
|
|||
)
|
||||
last_state = await self.async_get_last_state()
|
||||
if last_state and last_state.state == STATE_ON:
|
||||
self._state = True
|
||||
await self.async_turn_on(adapt_lights=not self._only_once)
|
||||
else:
|
||||
self._state = False
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue