From a298b395dd59df31a89186a7017ae6e90df8b81e Mon Sep 17 00:00:00 2001 From: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com> Date: Tue, 24 Sep 2024 07:00:53 -0500 Subject: [PATCH] ensure descriptions can be empty --- frigate/api/event.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/frigate/api/event.py b/frigate/api/event.py index c66bd568c..eb98301b7 100644 --- a/frigate/api/event.py +++ b/frigate/api/event.py @@ -911,7 +911,11 @@ def set_description(id): json: dict[str, any] = request.get_json(silent=True) or {} new_description = json.get("description") - event.data["description"] = new_description or None + # ensure we can save an empty description + if new_description: + event.data["description"] = new_description + else: + event.data.pop("description", None) event.save() # If semantic search is enabled, update the index