1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-10-22 19:26:13 +02:00

Don't include tx value in calculation of balance sufficiency for cancel button disabling. (#6346)

This commit is contained in:
Dan J Miller 2019-03-26 12:17:36 -02:30 committed by GitHub
parent 1859de0a28
commit ef4894b9a0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -22,11 +22,11 @@ const mapStateToProps = (state, ownProps) => {
const { showFiatInTestnets } = preferencesSelector(state)
const isMainnet = getIsMainnet(state)
const { transactionGroup: { primaryTransaction } = {} } = ownProps
const { txParams: { gas: gasLimit, gasPrice, value } = {} } = primaryTransaction
const { txParams: { gas: gasLimit, gasPrice } = {} } = primaryTransaction
const selectedAccountBalance = accounts[getSelectedAddress(state)].balance
const hasEnoughCancelGas = primaryTransaction.txParams && isBalanceSufficient({
amount: value,
amount: '0x0',
gasTotal: getHexGasTotal({
gasPrice: increaseLastGasPrice(gasPrice),
gasLimit,