-
Notifications
You must be signed in to change notification settings - Fork 541
Description
Is your request related to a problem?
This request is inspired by #1219
Feature Description
Account Center widget shows the history of connected metamask wallets even though some of them could have been disconnected already by the user in the metamask directly and since there is no 'wallet disconnected' event we just don't know when this happens. Here's an example

As you can see I only have ...a42d wallet connected in metamask and have since disconnected ihor.eth yet I can select it in the Account Center.
I propose that whenever the metamask wallet is selected in the account center we send the wallet_getPermissions request first and look inside the caveats array.

If the wallet is not there anymore we send the wallet_requestPermissions request so that the user can select that wallet again and make it active. We can also "clean up" other wallet addresses that are still lingering in the Account Center at this time.
Alternative Solutions
Not that I'm aware of, I've looked all over Metamask docs.
Anything else?
We could also send the wallet_requestPermissions request whenever someone


