metamask-extension
metamask-extension copied to clipboard
Improve how we handle wallet_addEthereumChain with same chainID but different rpc urls
Context: https://github.com/MetaMask/metamask-extension/issues/15840
We should better communicate to users that the dapp is proposing to add a network they already have, but with a different rpc url and give users the choice to switch to the network they already have or adding it as a new custom network with the new rpc url - or maybe even replacing the current rpc url. This ticket needs more definition and design before it's ready for development.
Can we please also consider an option (maybe advanced settings) to ignore prompts to add RPCs for networks where one is already defined.
For example, if I am using a private RPC I'm not interested in adding another RPC for the same network.
Actually most times adding a new RPC where one already exists is probably not helpful and could be used to spam or inject malicious RPCs for unknowing users.
Thanks 🙏
The copy mentioned here https://github.com/MetaMask/metamask-extension/issues/16712 should be considered/applied for this issue as well.