diff options
| author | Henry Jameson <me@hjkos.com> | 2023-11-19 13:54:26 +0200 |
|---|---|---|
| committer | Henry Jameson <me@hjkos.com> | 2023-11-19 13:54:26 +0200 |
| commit | a564fc1a1f91faf2a418fd6affadbd42c98825d8 (patch) | |
| tree | 27714d37056a3f8d04a986b0a75e53d6ddedbee2 /src | |
| parent | c216340001f1b019b58a075c173b78ff9f4dafa7 (diff) | |
consistentcy and bugfix
Diffstat (limited to 'src')
| -rw-r--r-- | src/modules/notifications.js | 2 | ||||
| -rw-r--r-- | src/services/desktop_notification_utils/desktop_notification_utils.js | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/modules/notifications.js b/src/modules/notifications.js index 9bd38220..c1f5a63e 100644 --- a/src/modules/notifications.js +++ b/src/modules/notifications.js @@ -150,7 +150,7 @@ export const notifications = { id, credentials: rootState.users.currentUser.credentials }).then(() => { - closeDesktopNotification(rootState, id) + closeDesktopNotification(rootState, { id }) }) }, dismissNotificationLocal ({ rootState, commit }, { id }) { diff --git a/src/services/desktop_notification_utils/desktop_notification_utils.js b/src/services/desktop_notification_utils/desktop_notification_utils.js index bde9f18c..80b8c6e0 100644 --- a/src/services/desktop_notification_utils/desktop_notification_utils.js +++ b/src/services/desktop_notification_utils/desktop_notification_utils.js @@ -21,7 +21,7 @@ export const showDesktopNotification = (rootState, desktopNotificationOpts) => { } } -export const closeDesktopNotification = (rootState, id) => { +export const closeDesktopNotification = (rootState, { id }) => { if (!('Notification' in window && window.Notification.permission === 'granted')) return if (isSWSupported()) { @@ -33,6 +33,6 @@ export const closeAllDesktopNotifications = (rootState) => { if (!('Notification' in window && window.Notification.permission === 'granted')) return if (isSWSupported()) { - swCloseDesktopNotification() + swCloseDesktopNotification({}) } } |
