diff --git a/apps/nspanel-lovelace-ui/luibackend/controller.py b/apps/nspanel-lovelace-ui/luibackend/controller.py index 407ddd8f..3d49d357 100644 --- a/apps/nspanel-lovelace-ui/luibackend/controller.py +++ b/apps/nspanel-lovelace-ui/luibackend/controller.py @@ -327,8 +327,8 @@ class LuiController(object): else: apis.ha_api.get_entity(entity_id).call_service("turn_off") if button_type == "media-shuffle": - cur_suffle = apis.ha_api.get_entity(entity_id).shuffle - apis.ha_api.get_entity(entity_id).call_service("shuffle_set", shuffle=!cur_suffle) + suffle = not apis.ha_api.get_entity(entity_id).shuffle + apis.ha_api.get_entity(entity_id).call_service("shuffle_set", shuffle=suffle) if button_type == "volumeSlider": pos = int(value) # HA wants this value between 0 and 1 as float @@ -401,4 +401,4 @@ class LuiController(object): entity = apis.ha_api.get_entity(entity_id) option = entity.attributes.effect_list[int(value)] entity.call_service("select_effect", option=option) - \ No newline at end of file +