Add --transition to bulb-specific cli commands, fix turn_{on,off} signatures (#81)

This commit is contained in:
Teemu R
2020-07-06 16:10:28 +02:00
committed by GitHub
parent 44e2998705
commit 4d722e25c1
6 changed files with 25 additions and 20 deletions

View File

@@ -48,11 +48,11 @@ class SmartPlug(SmartDevice):
sys_info = self.sys_info
return bool(sys_info["relay_state"])
async def turn_on(self):
async def turn_on(self, **kwargs):
"""Turn the switch on."""
return await self._query_helper("system", "set_relay_state", {"state": 1})
async def turn_off(self):
async def turn_off(self, **kwargs):
"""Turn the switch off."""
return await self._query_helper("system", "set_relay_state", {"state": 0})