fix checking web3

This commit is contained in:
Iuri Matias 2018-06-11 16:27:39 -04:00
parent 57ef573142
commit 5f8f7f35ac
2 changed files with 2 additions and 2 deletions

View File

@ -26,7 +26,7 @@ EmbarkJS.Contract = function(options) {
this.code = '0x' + options.code;
//this.web3 = options.web3 || web3;
this.web3 = options.web3;
if (!this.web3 && typeof ('web3') !== 'undefined') {
if (!this.web3 && typeof (web3) !== 'undefined') {
this.web3 = web3;
} else if (!this.web3) {
this.web3 = window.web3;

View File

@ -26,7 +26,7 @@ EmbarkJS.Contract = function(options) {
this.code = '0x' + options.code;
//this.web3 = options.web3 || web3;
this.web3 = options.web3;
if (!this.web3 && typeof ('web3') !== 'undefined') {
if (!this.web3 && typeof (web3) !== 'undefined') {
this.web3 = web3;
} else if (!this.web3) {
this.web3 = window.web3;