fix for the fix

Signed-off-by: VoR0220 <catalanor0220@gmail.com>
This commit is contained in:
VoR0220 2018-05-30 14:34:36 -05:00
parent 4d65ccec7a
commit 21b530fad2
1 changed files with 4 additions and 4 deletions

View File

@ -28,9 +28,11 @@ EmbarkJS.Contract = function(options) {
ContractClass = new this.web3.eth.Contract(this.abi, this.address); ContractClass = new this.web3.eth.Contract(this.abi, this.address);
ContractClass.setProvider(this.web3.currentProvider); ContractClass.setProvider(this.web3.currentProvider);
ContractClass.options.data = this.code; ContractClass.options.data = this.code;
ContractClass = this.web3.eth.contract(this.abi); ContractClass.abi = ContractClass.options.abi;
return ContractClass; return ContractClass;
} else { } else {
ContractClass = this.web3.eth.contract(this.abi);
this.eventList = []; this.eventList = [];
if (this.abi) { if (this.abi) {
@ -42,8 +44,6 @@ EmbarkJS.Contract = function(options) {
} }
} }
ContractClass.abi = ContractClass.options.abi;
var messageEvents = function() { var messageEvents = function() {
this.cb = function() {}; this.cb = function() {};
}; };