Skip to content

Add object detection, tracking, mobile notifications, and search to any security camera.

fix when no is_on

roryclear6b2b0471e66b
diff --git a/clearcam.py b/clearcam.py
index e7dfe0f..9266e85 100644
--- a/clearcam.py
+++ b/clearcam.py
@@ -389,7 +389,7 @@ class RollingClassCounter:
return counts, max_reached
def is_active(self, offset=0):
- if not self.is_on: return False
+ if not getattr(self, "is_on", False): return False
if not self.sched: return True
now = time.localtime()
time_of_day = now.tm_hour * 3600 + now.tm_min * 60 + now.tm_sec