Skip to content

Commit

Permalink
Merge pull request #210 from MTrab:Fix-DeviceCapability-check-for-edg…
Browse files Browse the repository at this point in the history
…ecut

Fix capability check for OTS and EdgeCut
  • Loading branch information
MTrab committed Apr 17, 2024
2 parents 542ce6b + a52b903 commit 0a816ab
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pyworxcloud/utils/capability.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ def __init__(self, device_data: Any | None = None) -> int:

try:
if "sc" in device_data["last_status"]["payload"]["cfg"]:
if "ots" in device_data["last_status"]["payload"]["cfg"]["sc"]:
if (
"ots" in device_data["last_status"]["payload"]["cfg"]["sc"]
or "once" in device_data["last_status"]["payload"]["cfg"]["sc"]
):
self.add(DeviceCapability.ONE_TIME_SCHEDULE)
self.add(DeviceCapability.EDGE_CUT)
if (
Expand Down

0 comments on commit 0a816ab

Please sign in to comment.