-
Notifications
You must be signed in to change notification settings - Fork 340
add last failed tx processing #2
base: master
Are you sure you want to change the base?
Conversation
so the issue was about to resend any failed tx by querying a tx hash
|
added page /#/checktx |
src/stores/txStore.js
Outdated
} | ||
|
||
async _multisend({slice, addPerTx}) { | ||
alert('ffff') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
?? @LTailor
src/components/checkTx.js
Outdated
onSubmit(e){ | ||
e.preventDefault() | ||
|
||
this.tokenStore.setDecimals(0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
? why decimals 0 ?
src/components/checkTx.js
Outdated
import { inject, observer } from "mobx-react"; | ||
import swal from 'sweetalert'; | ||
import generateElement from '../generateElement' | ||
import Example from './example.json' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do you need all of those dependencies?
src/stores/txStore.js
Outdated
const defaultAccount = this.web3Store.defaultAccount; | ||
const web3 = this.web3Store.web3; | ||
const status = await window.fetch(`https://${trustApiName}.etherscan.io/api?module=transaction&action=getstatus&txhash=${txHash}`) | ||
.then((res) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please don't use Promises.
Use await
I have done fixes for cleaning ( I forget to commit deleting of debug alerts and other fixes before last PR). I reviewed other classes, and I think that tokenStore and gasPriceStore should be refactored, because many methods violates The Single Responsibility Principle and it was hard to me make additional features and fixes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved
this fix checks last failed tx when user enters token address