We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 36c7c0f commit 90ed590Copy full SHA for 90ed590
plugwise/smile.py
@@ -401,12 +401,13 @@ async def set_switch_state(
401
locator = f'appliance[@id="{appl_id}"]/{switch.actuator}/{switch.func_type}'
402
found: list[etree] = self._domain_objects.findall(locator)
403
for item in found:
404
+ # multiple types of e.g. toggle_functionality present
405
if (sw_type := item.find("type")) is not None:
406
if sw_type.text == switch.act_type:
407
switch_id = item.attrib["id"]
- else:
408
+ break
409
+ else: # actuators with a single item like relay_functionality
410
- break
411
412
data = (
413
f"<{switch.func_type}>"
0 commit comments