Commit 075d03ef authored by yann300's avatar yann300

fix tryTillResponse

parent 7013ed1e
...@@ -191,8 +191,8 @@ TxRunner.prototype.execute = function (args, callback) { ...@@ -191,8 +191,8 @@ TxRunner.prototype.execute = function (args, callback) {
function tryTillResponse (txhash, done) { function tryTillResponse (txhash, done) {
executionContext.web3().eth.getTransactionReceipt(txhash, function (err, result) { executionContext.web3().eth.getTransactionReceipt(txhash, function (err, result) {
if (!err && !result) { if (err || !result) {
// Try again with a bit of delay // Try again with a bit of delay if error or if result still null
setTimeout(function () { tryTillResponse(txhash, done) }, 500) setTimeout(function () { tryTillResponse(txhash, done) }, 500)
} else { } else {
done(err, { done(err, {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment