Keep looping if address is null

This made embark-framework work for me. (More often than not.)
This commit is contained in:
linagee 2015-07-24 18:06:02 -06:00
parent e72a2e1aa9
commit 634a7bfe1e

View File

@ -71,7 +71,7 @@ Deploy.prototype.deploy_contracts = function(env) {
console.log('trying to obtain ' + className + ' address...');
var receipt = null;
while ((receipt = web3.eth.getTransactionReceipt(transactionHash)) === null) {
while ((receipt = web3.eth.getTransactionReceipt(transactionHash)) === null || receipt.contractAddress === null) {
sleep.sleep(1);
}
var contractAddress = receipt.contractAddress;