mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
LIFX: refresh state after stopping an effect
This clears the internal cache in case polling picked up the state as set by an effect. For example, aborting an effect by selecting a new brightness could keep a color set by the effect.
This commit is contained in:
parent
dbd6f7e4ed
commit
71d909483c
@ -205,6 +205,7 @@ class LIFXEffect(object):
|
|||||||
light.device.set_color(light.effect_data.color)
|
light.device.set_color(light.effect_data.color)
|
||||||
yield from asyncio.sleep(0.5)
|
yield from asyncio.sleep(0.5)
|
||||||
light.effect_data = None
|
light.effect_data = None
|
||||||
|
yield from light.refresh_state()
|
||||||
self.lights.remove(light)
|
self.lights.remove(light)
|
||||||
|
|
||||||
def from_poweroff_hsbk(self, light, **kwargs):
|
def from_poweroff_hsbk(self, light, **kwargs):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user