Skip to content

Commit

Permalink
firebaseAppがない時はトークンを削除しないように
Browse files Browse the repository at this point in the history
  • Loading branch information
nokhnaton committed Oct 28, 2024
1 parent fa02aad commit 1c27fc6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/lib/notification/notification.ts
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ export const deleteToken = () => {
if (window.Notification?.permission !== 'granted') return

const firebaseApp = getFirebaseApp()
if (!firebaseApp) return
const messaging = getMessaging(firebaseApp)
deleteTokenFb(messaging)
}
Expand Down

0 comments on commit 1c27fc6

Please sign in to comment.