From ad5202776038ddfa1ec3feeefc36ed9b7888a0a6 Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Wed, 26 Aug 2026 14:38:00 +0300 Subject: [PATCH] push notifications fix --- src/lib/push_notifications_plugin.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/push_notifications_plugin.js b/src/lib/push_notifications_plugin.js index 951eb2c4b..b3f6885d7 100644 --- a/src/lib/push_notifications_plugin.js +++ b/src/lib/push_notifications_plugin.js @@ -6,7 +6,7 @@ import { useUsersStore } from 'src/stores/users.js' export const piniaPushNotificationsPlugin = ({ store }) => { const validActions = { sync_config: new Set(['setPreference']), - interface: new Set(['setNotificationPermission', 'setLoginStatus']), + interface: new Set(['setNotificationPermission', 'onLogin', 'onLogout']), } if (!validActions[store.$id]) return // Not applicable to the store @@ -21,7 +21,7 @@ export const piniaPushNotificationsPlugin = ({ store }) => { useInterfaceStore().notificationPermission === 'granted' let permissionPresent = useInterfaceStore().notificationPermission !== undefined - let user = !!useUsersStore().currentUser + let user = useUsersStore().loggedIn if (store.$id === 'instance') { if (actionName === 'set' && args[0].path === 'vapidPublicKey') {