From 3b59f2eefdd402f72825a3a7d990d37a007b8e94 Mon Sep 17 00:00:00 2001 From: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com> Date: Sun, 22 Nov 2026 07:35:14 -0600 Subject: [PATCH] don't end push notification titles with "detected in" when there are no zones --- frigate/comms/webpush.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/frigate/comms/webpush.py b/frigate/comms/webpush.py index 5235a0b72c..2dd3d1c0f5 100644 --- a/frigate/comms/webpush.py +++ b/frigate/comms/webpush.py @@ -617,7 +617,14 @@ class WebPushClient(Communicator): else: formatted_zone_names.append(titlecase(zone_name.replace("_", " "))) - title = f"{titlecase(', '.join(sorted_objects).replace('_', ' '))}{' was' if state == 'end' else ''} detected in {', '.join(formatted_zone_names)}" + object_names = titlecase( + ", ".join(sorted(sorted_objects)).replace("_", " ") + ) + title = f"{object_names}{' was' if state == 'end' else ''} detected" + + if formatted_zone_names: + title += f" in {', '.join(formatted_zone_names)}" + message = f"Detected on {camera_name}" if ended: