mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-08-02 17:12:16 +03:00
Disable detection by default (#16980)
* Enable detection by default * Migrate config to have detect enabled if it is not
This commit is contained in:
@@ -300,6 +300,12 @@ def migrate_016_0(config: dict[str, dict[str, any]]) -> dict[str, dict[str, any]
|
||||
"""Handle migrating frigate config to 0.16-0"""
|
||||
new_config = config.copy()
|
||||
|
||||
# migrate config that does not have detect -> enabled explicitly set to have it enabled
|
||||
if new_config.get("detect", {}).get("enabled") is None:
|
||||
detect_config = new_config.get("detect", {})
|
||||
detect_config["enabled"] = True
|
||||
new_config["detect"] = detect_config
|
||||
|
||||
for name, camera in config.get("cameras", {}).items():
|
||||
camera_config: dict[str, dict[str, any]] = camera.copy()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user