Skip to content
This repository has been archived by the owner on Oct 4, 2023. It is now read-only.

Commit

Permalink
[Flare-120] Avoid hitting notification settings on each session (#2262)
Browse files Browse the repository at this point in the history
  • Loading branch information
raymondjacobson authored Nov 16, 2022
1 parent cc9a880 commit 40e0c14
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 4 deletions.
2 changes: 0 additions & 2 deletions packages/mobile/src/store/notifications/sagas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,9 @@ export function* markedAllNotificationsViewed() {
}

function* notificationPollingDaemon() {
const audiusBackendInstance = yield* getContext('audiusBackendInstance')
const remoteConfigInstance = yield* getContext('remoteConfigInstance')
yield* call(waitForBackendSetup)
yield* call(waitForValue, getHasAccount, {})
yield* call(audiusBackendInstance.getEmailNotificationSettings)

yield* takeEvery(ENTER_FOREGROUND, getNotifications, false)

Expand Down
2 changes: 0 additions & 2 deletions packages/web/src/store/notifications/sagas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,9 @@ import { isElectron } from 'utils/clientUtil'
const { getHasAccount } = accountSelectors

function* notificationPollingDaemon() {
const audiusBackendInstance = yield* getContext('audiusBackendInstance')
const remoteConfigInstance = yield* getContext('remoteConfigInstance')
yield* call(waitForBackendSetup)
yield* call(waitForValue, getHasAccount, {})
yield* call(audiusBackendInstance.getEmailNotificationSettings)

// Set up daemon that will watch for browser into focus and refetch notifications
// as soon as it goes into focus
Expand Down

0 comments on commit 40e0c14

Please sign in to comment.