From 7a28783924c1c4c77fe8e5cc259fcd27a2371a45 Mon Sep 17 00:00:00 2001 From: Dan J Miller Date: Wed, 7 Oct 2020 14:25:38 -0230 Subject: [PATCH] Prevent user from submitting swap if they do not have enough for the max gas fee (#9500) --- ui/app/pages/swaps/view-quote/view-quote.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/app/pages/swaps/view-quote/view-quote.js b/ui/app/pages/swaps/view-quote/view-quote.js index bd0b73203..03b2b8d63 100644 --- a/ui/app/pages/swaps/view-quote/view-quote.js +++ b/ui/app/pages/swaps/view-quote/view-quote.js @@ -142,7 +142,7 @@ export default function ViewQuote () { ) ) - const gasTotalInWeiHex = calcGasTotal(usedGasLimit, gasPrice) + const gasTotalInWeiHex = calcGasTotal(maxGasLimit, gasPrice) const { tokensWithBalances } = useTokenTracker(swapsTokens) const balanceToken = fetchParamsSourceToken === ETH_SWAPS_TOKEN_OBJECT.address