Skip to content

Commit

Permalink
Merge pull request #98 from roflcoopter/hotfix/mqtt_sensor
Browse files Browse the repository at this point in the history
fix crash when mqtt not configured
  • Loading branch information
roflcoopter authored Dec 7, 2020
2 parents 92cf219 + 49055e5 commit 5015519
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/lib/nvr.py
Original file line number Diff line number Diff line change
Expand Up @@ -464,6 +464,9 @@ def process_motion_event(self):
self.camera.scan_for_objects.clear()

def update_status_sensor(self):
if not self._mqtt.mqtt_queue:
return

status = "unknown"
if self.recorder.is_recording:
status = "recording"
Expand Down

0 comments on commit 5015519

Please sign in to comment.