remove erroneous check for move threads (#8031)

This commit is contained in:
Josh Hawkins 2023-10-07 09:18:07 -05:00 committed by GitHub
parent 20c2ab39bc
commit fe9fcf3eaa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -237,13 +237,12 @@ class PtzAutoTracker:
self.onvif.get_camera_status(camera_name) self.onvif.get_camera_status(camera_name)
# movement thread per camera # movement thread per camera
if not self.move_threads or not self.move_threads[camera_name]: self.move_threads[camera_name] = threading.Thread(
self.move_threads[camera_name] = threading.Thread( name=f"move_thread_{camera_name}",
name=f"move_thread_{camera_name}", target=partial(self._process_move_queue, camera_name),
target=partial(self._process_move_queue, camera_name), )
) self.move_threads[camera_name].daemon = True
self.move_threads[camera_name].daemon = True self.move_threads[camera_name].start()
self.move_threads[camera_name].start()
if cam.onvif.autotracking.movement_weights: if cam.onvif.autotracking.movement_weights:
self.intercept[camera_name] = cam.onvif.autotracking.movement_weights[0] self.intercept[camera_name] = cam.onvif.autotracking.movement_weights[0]