Use window for check

This commit is contained in:
Anthony Laibe 2018-11-01 11:45:09 +01:00
parent 103a78fa43
commit ec94088530

View File

@ -30,7 +30,7 @@ Blockchain.connect = function(connectionList, opts, doneCb) {
}
const connectWeb3 = async (next) => {
if (ethereum) {
if (window.ethereum) {
try {
await ethereum.enable();
web3.setProvider(ethereum);