From 65ba018aad5c09cf5f5b96df559cb543e4a9e980 Mon Sep 17 00:00:00 2001 From: Whymarrh Whitby Date: Mon, 1 Oct 2018 14:04:50 -0230 Subject: [PATCH] Only use current network txs when calculating "Reject All" --- .../confirm-transaction-base.container.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js b/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js index 2e7677a45..b34067686 100644 --- a/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js +++ b/ui/app/components/pages/confirm-transaction-base/confirm-transaction-base.container.js @@ -53,6 +53,7 @@ const mapStateToProps = (state, props) => { selectedAddress, selectedAddressTxList, assetImages, + network, unapprovedTxs, } = metamask const assetImage = assetImages[txParamsToAddress] @@ -68,7 +69,11 @@ const mapStateToProps = (state, props) => { const transaction = R.find(({ id }) => id === transactionId)(selectedAddressTxList) const transactionStatus = transaction ? transaction.status : '' - const unapprovedTxCount = valuesFor(unapprovedTxs).length + const currentNetworkUnapprovedTxs = R.filter( + ({ metamaskNetworkId }) => metamaskNetworkId === network, + valuesFor(unapprovedTxs), + ) + const unapprovedTxCount = currentNetworkUnapprovedTxs.length return { balance,