mevblocker / web

https://mevblocker.io
7 stars 1 forks source link

Improve error for Metamask in-app browser #41

Closed anxolin closed 11 months ago

anxolin commented 1 year ago

Add a better message for Metamask in-app browser

Aparently Metamask in-app browswe response for adding the network return a different code and message than the SAME app using Wallet Connect.

This PR just makes sure we handle the error message better to show the following message:

image

Test

vercel[bot] commented 1 year ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
mevblocker-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 19, 2023 2:33pm
anxolin commented 1 year ago

@elena-zh for some reason i cannot assign you as reviewer. But maybe you could double check this one with low prio

elena-zh commented 1 year ago

Hey @anxolin , when I open the app in the mobile MM browser, everything works as you described! However, I noticed that on the 1st attempt to add the network to MM I see the this message (connected using WC) image

When I press once again on the button, I see the correct message image

Is this OK?