Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix WalletConnection alert #598

Merged
merged 2 commits into from
Sep 12, 2023
Merged

Fix WalletConnection alert #598

merged 2 commits into from
Sep 12, 2023

Conversation

michalsmiarowski
Copy link
Contributor

There was a bug that caused the walletconnection alert to not show up the second time if the error message stays the same.

This commit fixes that.

image

To see if it works you can:

  1. Click "Connect Wallet"
  2. Choose "WalletConnect"
  3. Close the WalletConnect modal with X button
  4. The "Connection request reset. Please try again" alert should appear in the top right corner.
  5. Close the alert
  6. Repeat steps 1-3
  7. The "Connection request reset. Please try again" alert should appear again

There was a bug - the walletconnection alert did not show up second time if the
error message stays the same.

This commit fixes that.
@github-actions
Copy link

We should never change or update the state directly and `error` is a state
variable. Instead we call `deactivate` function from `useWeb3React` to clear the
state.
@github-actions
Copy link

github-actions bot commented Sep 6, 2023

@michalsmiarowski michalsmiarowski self-assigned this Sep 6, 2023
@r-czajkowski r-czajkowski merged commit bfa11b9 into main Sep 12, 2023
5 checks passed
@r-czajkowski r-czajkowski deleted the wallet-connection-alert-fix branch September 12, 2023 09:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants