consistentcy and bugfix

neckbeard
Henry Jameson 10 months ago
parent c216340001
commit a564fc1a1f

@ -150,7 +150,7 @@ export const notifications = {
id, id,
credentials: rootState.users.currentUser.credentials credentials: rootState.users.currentUser.credentials
}).then(() => { }).then(() => {
closeDesktopNotification(rootState, id) closeDesktopNotification(rootState, { id })
}) })
}, },
dismissNotificationLocal ({ rootState, commit }, { id }) { dismissNotificationLocal ({ rootState, commit }, { id }) {

@ -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 (!('Notification' in window && window.Notification.permission === 'granted')) return
if (isSWSupported()) { if (isSWSupported()) {
@ -33,6 +33,6 @@ export const closeAllDesktopNotifications = (rootState) => {
if (!('Notification' in window && window.Notification.permission === 'granted')) return if (!('Notification' in window && window.Notification.permission === 'granted')) return
if (isSWSupported()) { if (isSWSupported()) {
swCloseDesktopNotification() swCloseDesktopNotification({})
} }
} }

Loading…
Cancel
Save