mirror of
https://github.com/trezor/trezor-wallet
synced 2024-11-24 01:08:27 +00:00
fixed PendingTx resolve
This commit is contained in:
parent
c77c8f0141
commit
fa9b3a794e
@ -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({
|
||||
|
Loading…
Reference in New Issue
Block a user