Fixed light not turning off
This commit is contained in:
parent
98a2d6551c
commit
6ba8313609
1 changed files with 2 additions and 2 deletions
|
@ -225,8 +225,8 @@ def set_light_state(target_light_state: bool) -> bool:
|
||||||
|
|
||||||
# Adjust light as necessary
|
# Adjust light as necessary
|
||||||
target_scene = get_scene_for_time(datetime.now().time())
|
target_scene = get_scene_for_time(datetime.now().time())
|
||||||
|
if target_light_state and target_scene:
|
||||||
# Set to specific scene if exists
|
# Set to specific scene if exists
|
||||||
if target_scene:
|
|
||||||
hue.set_group_scene(hue_conf['light_group'], target_scene)
|
hue.set_group_scene(hue_conf['light_group'], target_scene)
|
||||||
logging.debug(
|
logging.debug(
|
||||||
f'Light state changed to {target_light_state} with scene {target_scene}')
|
f'Light state changed to {target_light_state} with scene {target_scene}')
|
||||||
|
|
Loading…
Reference in a new issue