Skip to content

Commit

Permalink
fix critical error
Browse files Browse the repository at this point in the history
  • Loading branch information
0xSero committed Jul 1, 2024
1 parent 9970e64 commit 01688a9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion wallets/metamask/src/utils/waitFor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ export const fixCriticalError = async (page: Page) => {
await page.reload()
await waitForMetaMaskWindowToBeStable(page)
} else if (times === 4) {
await module.exports.waitAndClick(ErrorSelectors.criticalErrorRestartButton)
const restartButton = await page.locator(ErrorSelectors.criticalErrorRestartButton)
await restartButton.click()
await waitForMetaMaskWindowToBeStable(page)
} else {
throw new Error('[fixCriticalError] Max amount of retries to fix critical metamask error has been reached.')
Expand Down

0 comments on commit 01688a9

Please sign in to comment.