add a check for the window var itself

pull/7/head
Iuri Matias 7 years ago
parent bba0189282
commit 328913afac
  1. 2
      remix-lib/src/execution/execution-context.js

@ -11,7 +11,7 @@ var rlp = ethUtil.rlp
var injectedProvider
var web3
if (typeof window.web3 !== 'undefined') {
if (typeof window !== 'undefined' && typeof window.web3 !== 'undefined') {
injectedProvider = window.web3.currentProvider
web3 = new Web3(injectedProvider)
} else {

Loading…
Cancel
Save