pyhOn/pyhon/appliances/wh.py
Vadym Melnychuk a9fd05f3f5 fixed build
2023-07-11 17:40:04 +03:00

10 lines
303 B
Python

from typing import Any, Dict
from pyhon.appliances.base import ApplianceBase
class Appliance(ApplianceBase):
def attributes(self, data: Dict[str, Any]) -> Dict[str, Any]:
data = super().attributes(data)
data["active"] = data["parameters"]["onOffStatus"] == "1"
return data