diff --git a/lib/deploy_tracker.js b/lib/deploy_tracker.js index 8012e626..9f446a9c 100644 --- a/lib/deploy_tracker.js +++ b/lib/deploy_tracker.js @@ -40,7 +40,9 @@ DeployTracker.prototype.trackContract = function(contractName, code, args, addre }; DeployTracker.prototype.getContract = function(contractName, code, args) { - return this.currentChain.contracts[this.web3.sha3(code + contractName + args.join(','))]; + var contract = this.currentChain.contracts[this.web3.sha3(code + contractName + args.join(','))]; + if (contract && contract.address === undefined) { return false; } + return contract; }; // TODO: abstract this