aboutsummaryrefslogtreecommitdiffstats
path: root/app/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'app/scripts')
-rw-r--r--app/scripts/controllers/transactions.js8
-rw-r--r--app/scripts/lib/tx-gas-utils.js3
2 files changed, 10 insertions, 1 deletions
diff --git a/app/scripts/controllers/transactions.js b/app/scripts/controllers/transactions.js
index 73aadb292..9c3618e60 100644
--- a/app/scripts/controllers/transactions.js
+++ b/app/scripts/controllers/transactions.js
@@ -57,6 +57,14 @@ module.exports = class TransactionController extends EventEmitter {
})
})
+ this.txStateManager.getFilteredTxList({
+ status: 'approved',
+ }).forEach((txMeta) => {
+ const txSignError = new Error('Transaction found as "approved" during boot - possibly stuck during signing')
+ this.txStateManager.setTxStatusFailed(txMeta.id, txSignError)
+ })
+
+
this.store = this.txStateManager.store
this.txStateManager.on('tx:status-update', this.emit.bind(this, 'tx:status-update'))
this.nonceTracker = new NonceTracker({
diff --git a/app/scripts/lib/tx-gas-utils.js b/app/scripts/lib/tx-gas-utils.js
index e80e0467e..f68f3a9e2 100644
--- a/app/scripts/lib/tx-gas-utils.js
+++ b/app/scripts/lib/tx-gas-utils.js
@@ -12,7 +12,8 @@ its passed ethquery
and used to do things like calculate gas of a tx.
*/
-module.exports = class txProvideUtil {
+module.exports = class TxGasUtil {
+
constructor (provider) {
this.query = new EthQuery(provider)
}