diff options
Diffstat (limited to 'src/lib/notifee.ts')
-rw-r--r-- | src/lib/notifee.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/notifee.ts b/src/lib/notifee.ts index fb0afdd60..4baf64050 100644 --- a/src/lib/notifee.ts +++ b/src/lib/notifee.ts @@ -1,9 +1,9 @@ import notifee, {EventType} from '@notifee/react-native' import {AppBskyEmbedImages} from '@atproto/api' import {RootStoreModel} from 'state/models/root-store' -import {TabPurpose} from 'state/models/navigation' import {NotificationsViewItemModel} from 'state/models/notifications-view' import {enforceLen} from 'lib/strings/helpers' +import {resetToTab} from '../Navigation' export function init(store: RootStoreModel) { store.onUnreadNotifications(count => notifee.setBadgeCount(count)) @@ -16,7 +16,7 @@ export function init(store: RootStoreModel) { store.log.debug('Notifee foreground event', {type}) if (type === EventType.PRESS) { store.log.debug('User pressed a notifee, opening notifications') - store.nav.switchTo(TabPurpose.Notifs, true) + resetToTab('NotificationsTab') } }) notifee.onBackgroundEvent(async _e => {}) // notifee requires this but we handle it with onForegroundEvent |