Commit f76a82a5 authored by Pietro Saccardi's avatar Pietro Saccardi
Browse files

Bugfix: triggering event only when needed.

If it was triggered and we are turning off motion detection, then raise
event.
parent 3b314fa4
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -95,7 +95,7 @@ class RatcamTelegramPlugin(TelegramProcessBase, MediaReceiver, MotionDetectorRes
        if not self._motion_detection_enabled and enabled and self.motion_detector_plugin.triggered:
            self._motion_detection_enabled = True
            self.motion_status_changed(True)
        elif self._motion_detection_enabled and not enabled and not self.motion_detector_plugin.triggered:
        elif self._motion_detection_enabled and not enabled and self.motion_detector_plugin.triggered:
            self.motion_status_changed(False)
            self._motion_detection_enabled = False
        else: