Merge pull request #25 from embark-framework/bugfix/check-for-window
Use window for check
This commit is contained in:
commit
0e3fe0dd5e
|
@ -30,7 +30,7 @@ Blockchain.connect = function(connectionList, opts, doneCb) {
|
||||||
}
|
}
|
||||||
|
|
||||||
const connectWeb3 = async (next) => {
|
const connectWeb3 = async (next) => {
|
||||||
if (ethereum) {
|
if (window.ethereum) {
|
||||||
try {
|
try {
|
||||||
await ethereum.enable();
|
await ethereum.enable();
|
||||||
web3.setProvider(ethereum);
|
web3.setProvider(ethereum);
|
||||||
|
|
Loading…
Reference in New Issue