Skip to content

Commit daa5fe9

Browse files
committed
Alternative solution
1 parent f45e8f1 commit daa5fe9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

plugwise/legacy/smile.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -234,17 +234,17 @@ async def set_switch_state(
234234
"""Set the given State of the relevant Switch."""
235235
switch = Munch()
236236
switch.actuator = "actuator_functionalities"
237+
switch.func_type = "relay_functionality"
237238
if self._stretch_v2:
238239
switch.actuator = "actuators"
239-
# From #833 it seems this is not correct: switch.func_type = "relay_functionality"
240-
switch.func_type = "relay"
240+
switch.func_type = "relay"
241241
switch.func = "state"
242242

243243
if members is not None:
244244
return await self._set_groupswitch_member_state(members, state, switch)
245245

246246
data = f"<{switch.func_type}><{switch.func}>{state}</{switch.func}></{switch.func_type}>"
247-
uri = f"{APPLIANCES};id={appl_id}/{switch.func_type}"
247+
uri = f"{APPLIANCES};id={appl_id}/relay"
248248

249249
if model == "relay":
250250
locator = (

0 commit comments

Comments
 (0)