From fc9d777dc3161b40c5c62bb65cb03e2c7d8f4380 Mon Sep 17 00:00:00 2001 From: Marie Date: Sun, 3 Nov 2024 17:59:50 +0100 Subject: upd: add notification for failures, add reasons for failure, apply suggestions --- packages/sw/src/scripts/create-notification.ts | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'packages/sw/src/scripts/create-notification.ts') diff --git a/packages/sw/src/scripts/create-notification.ts b/packages/sw/src/scripts/create-notification.ts index 9c56e338c7..8442552e3b 100644 --- a/packages/sw/src/scripts/create-notification.ts +++ b/packages/sw/src/scripts/create-notification.ts @@ -258,6 +258,13 @@ async function composeNotification(data: PushNotificationDataMap[keyof PushNotif data, }]; + case 'scheduledNoteFailed': + return [i18n.ts._notification.scheduledNoteFailed, { + body: data.body.reason, + badge: iconUrl('bell'), + data, + }]; + default: return null; } -- cgit v1.2.3-freya