diff --git a/src/universal-dapp.js b/src/universal-dapp.js index b660affec7..ec58a2669c 100644 --- a/src/universal-dapp.js +++ b/src/universal-dapp.js @@ -644,15 +644,14 @@ UniversalDApp.prototype.runTx = function (data, args, cb) { }; function tryTillResponse (web3, txhash, done) { - web3.eth.getTransactionReceipt(txhash, testResult); - - function testResult (err, address) { + web3.eth.getTransactionReceipt(txhash, function (err, address) { if (!err && !address) { + // Try again with a bit of delay setTimeout(function () { tryTillResponse(web3, txhash, done); }, 500); } else { done(err, address); } - } + }); } module.exports = UniversalDApp;