Skip to content

Commit

Permalink
Stop persisting after QuotaExceededError error (#1666)
Browse files Browse the repository at this point in the history
  • Loading branch information
marcinbodnar committed Jun 1, 2021
1 parent 52a672e commit bffb63c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/redux/store.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,12 @@ import { ACCOUNT_ID_SUFFIX } from '../utils/wallet'
const persistConfig = {
key: `wallet.near.org:${ACCOUNT_ID_SUFFIX}`,
storage,
blacklist: ['status', 'staking']
blacklist: ['status', 'staking'],
writeFailHandler: (error) => {
if (error.name === 'QuotaExceededError') {
persistor.pause()
}
}
}

export const history = createBrowserHistory()
Expand Down

0 comments on commit bffb63c

Please sign in to comment.