|
|
@ -72,7 +72,7 @@ export class TxRunner { |
|
|
|
resolve({ |
|
|
|
resolve({ |
|
|
|
result, |
|
|
|
result, |
|
|
|
tx, |
|
|
|
tx, |
|
|
|
transactionHash: result ? result.transactionHash : null |
|
|
|
transactionHash: result ? result['transactionHash'] : null |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
@ -176,7 +176,7 @@ export class TxRunner { |
|
|
|
const tx = { from: from, to: to, data: data, value: value } |
|
|
|
const tx = { from: from, to: to, data: data, value: value } |
|
|
|
|
|
|
|
|
|
|
|
if (useCall) { |
|
|
|
if (useCall) { |
|
|
|
tx.gas = gasLimit |
|
|
|
tx['gas'] = gasLimit |
|
|
|
return this.executionContext.web3().eth.call(tx, function (error, result) { |
|
|
|
return this.executionContext.web3().eth.call(tx, function (error, result) { |
|
|
|
callback(error, { |
|
|
|
callback(error, { |
|
|
|
result: result, |
|
|
|
result: result, |
|
|
@ -191,7 +191,7 @@ export class TxRunner { |
|
|
|
} |
|
|
|
} |
|
|
|
gasEstimationForceSend(err, () => { |
|
|
|
gasEstimationForceSend(err, () => { |
|
|
|
// callback is called whenever no error
|
|
|
|
// callback is called whenever no error
|
|
|
|
tx.gas = !gasEstimation ? gasLimit : gasEstimation |
|
|
|
tx['gas'] = !gasEstimation ? gasLimit : gasEstimation |
|
|
|
|
|
|
|
|
|
|
|
if (this._api.config.getUnpersistedProperty('doNotShowTransactionConfirmationAgain')) { |
|
|
|
if (this._api.config.getUnpersistedProperty('doNotShowTransactionConfirmationAgain')) { |
|
|
|
return this._executeTx(tx, null, this._api, promptCb, callback) |
|
|
|
return this._executeTx(tx, null, this._api, promptCb, callback) |
|
|
@ -203,7 +203,7 @@ export class TxRunner { |
|
|
|
return |
|
|
|
return |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
confirmCb(network, tx, tx.gas, (gasPrice) => { |
|
|
|
confirmCb(network, tx, tx['gas'], (gasPrice) => { |
|
|
|
return this._executeTx(tx, gasPrice, this._api, promptCb, callback) |
|
|
|
return this._executeTx(tx, gasPrice, this._api, promptCb, callback) |
|
|
|
}, (error) => { |
|
|
|
}, (error) => { |
|
|
|
callback(error) |
|
|
|
callback(error) |
|
|
|