Created
February 14, 2022 09:07
-
-
Save rapina/e19233f51ac1f55d52e75ed14b2d98f9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const checkNetwork = async () => { | |
| try { | |
| if (window.ethereum.networkVersion !== '4') { | |
| alert("Please connect to Rinkeby!") | |
| } | |
| } catch(error) { | |
| console.log(error) | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment