From fa9b3a794ee13ac09ae627ee4098d11ff7c84105 Mon Sep 17 00:00:00 2001 From: Szymon Lesisz Date: Wed, 9 May 2018 17:57:05 +0200 Subject: [PATCH] fixed PendingTx resolve --- src/js/actions/Web3Actions.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/js/actions/Web3Actions.js b/src/js/actions/Web3Actions.js index 4fccbf31..8a34832f 100644 --- a/src/js/actions/Web3Actions.js +++ b/src/js/actions/Web3Actions.js @@ -153,10 +153,10 @@ export function init(instance: ?Web3, coinIndex: number = 0): AsyncAction { const onBlockMined = async (error: ?Error, blockHash: ?string) => { if (error) { - // window.setTimeout(() => { - // // try again - // onBlockMined(new Error("manually_triggered_error"), undefined); - // }, 30000); + window.setTimeout(() => { + // try again + onBlockMined(new Error("manually_triggered_error"), undefined); + }, 30000); } if (blockHash) { @@ -315,7 +315,7 @@ export const getTransactionReceipt = (tx: PendingTx): AsyncAction => { const web3 = web3instance.web3; //web3.eth.getTransactionReceipt(txid, (error, tx) => { - web3.eth.getTransaction(tx.id, (error, receipt) => { + web3.eth.getTransaction(tx.id, (error: Error, receipt: any) => { if (receipt && receipt.blockNumber) { web3.eth.getBlock(receipt.blockHash, (error, block) => { dispatch({