diff --git a/src/components/UserProfile/UserSettings/UserNotificationSettings/UserNotificationsWebPush/index.tsx b/src/components/UserProfile/UserSettings/UserNotificationSettings/UserNotificationsWebPush/index.tsx index 9338ddb2..dca0fab0 100644 --- a/src/components/UserProfile/UserSettings/UserNotificationSettings/UserNotificationsWebPush/index.tsx +++ b/src/components/UserProfile/UserSettings/UserNotificationSettings/UserNotificationsWebPush/index.tsx @@ -163,9 +163,10 @@ const UserWebPushSettings = () => { const verifyWebPush = async () => { const enabled = await verifyPushSubscription(user?.id, currentSettings); setWebPushEnabled(enabled); - if (enabled) { - localStorage.setItem('pushNotificationsEnabled', 'true'); - } + localStorage.setItem( + 'pushNotificationsEnabled', + enabled ? 'true' : 'false' + ); }; if (user?.id) {