diff --git a/frigate/comms/webpush.py b/frigate/comms/webpush.py index d78c5254739..4efc927fe12 100644 --- a/frigate/comms/webpush.py +++ b/frigate/comms/webpush.py @@ -148,15 +148,15 @@ def send_alert(self, payload: dict[str, any]) -> None: endpoint = pusher.subscription_info["endpoint"] # set headers for notification behavior - headers = self.claim_headers[ - endpoint[0 : endpoint.index("/", 10)] - ].copy() + provider = endpoint[0 : endpoint.index("/", 10)] + headers = self.claim_headers[provider].copy() headers["urgency"] = "high" + ttl = 0 if "fcm.googleapis.com" in provider else 3600 # send message resp = pusher.send( headers=headers, - ttl=3600, + ttl=ttl, data=json.dumps( { "title": title, diff --git a/web/public/notifications-worker.js b/web/public/notifications-worker.js index 5e0e2a0f831..3e9b94a65ad 100644 --- a/web/public/notifications-worker.js +++ b/web/public/notifications-worker.js @@ -11,7 +11,6 @@ self.addEventListener("push", function (event) { icon: "/images/maskable-icon.png", image: data.image, badge: "/images/maskable-badge.png", - tag: data.id, data: { id: data.id, link: data.direct_url }, }); } else {