mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-05-09 15:05:26 +03:00
check for model too
This commit is contained in:
parent
bf99a0dd90
commit
12a2e61711
@ -177,8 +177,9 @@ def config(request: Request):
|
|||||||
|
|
||||||
# Add model plus data if plus is enabled
|
# Add model plus data if plus is enabled
|
||||||
if config["plus"]["enabled"]:
|
if config["plus"]["enabled"]:
|
||||||
if "path" in config["model"]:
|
model_path = config.get("model", {}).get("path")
|
||||||
model_json_path = FilePath(config["model"]["path"]).with_suffix(".json")
|
if model_path:
|
||||||
|
model_json_path = FilePath(model_path).with_suffix(".json")
|
||||||
try:
|
try:
|
||||||
with open(model_json_path, "r") as f:
|
with open(model_json_path, "r") as f:
|
||||||
model_plus_data = json.load(f)
|
model_plus_data = json.load(f)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user