mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-07-03 02:21:13 +03:00
Merge aeeaa37f3b into f3a352ef3f
This commit is contained in:
commit
a47c811dd1
@ -73,7 +73,12 @@ class CameraConfigUpdateSubscriber:
|
|||||||
|
|
||||||
base_topic = "config/cameras"
|
base_topic = "config/cameras"
|
||||||
|
|
||||||
if len(self.camera_configs) == 1:
|
# global subscribers must hear every camera; only narrow per-camera workers
|
||||||
|
is_global_subscriber = (
|
||||||
|
CameraConfigUpdateEnum.add in self.topics
|
||||||
|
or CameraConfigUpdateEnum.remove in self.topics
|
||||||
|
)
|
||||||
|
if not is_global_subscriber and len(self.camera_configs) == 1:
|
||||||
base_topic += f"/{list(self.camera_configs.keys())[0]}"
|
base_topic += f"/{list(self.camera_configs.keys())[0]}"
|
||||||
|
|
||||||
self.subscriber = ConfigSubscriber(
|
self.subscriber = ConfigSubscriber(
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user