Fix for metamask

This commit is contained in:
Franck Royer 2021-06-17 13:53:00 +10:00
parent fc987f8f58
commit ddf6a9501a
No known key found for this signature in database
GPG Key ID: A82ED75A8DFC50A4
1 changed files with 1 additions and 0 deletions

View File

@ -30,6 +30,7 @@ function App() {
useEffect(() => {
if (provider) return;
try {
window.ethereum.enable();
const _provider = new ethers.providers.Web3Provider(window.ethereum);
setProvider(_provider);
} catch (e) {