aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/pages/confirm-transaction-base/confirm-transaction-base.component.js
diff options
context:
space:
mode:
Diffstat (limited to 'ui/app/pages/confirm-transaction-base/confirm-transaction-base.component.js')
-rw-r--r--ui/app/pages/confirm-transaction-base/confirm-transaction-base.component.js9
1 files changed, 9 insertions, 0 deletions
diff --git a/ui/app/pages/confirm-transaction-base/confirm-transaction-base.component.js b/ui/app/pages/confirm-transaction-base/confirm-transaction-base.component.js
index 3c4e6dcac..c6a05cf0f 100644
--- a/ui/app/pages/confirm-transaction-base/confirm-transaction-base.component.js
+++ b/ui/app/pages/confirm-transaction-base/confirm-transaction-base.component.js
@@ -9,6 +9,7 @@ import { DEFAULT_ROUTE, CONFIRM_TRANSACTION_ROUTE } from '../../helpers/constant
import {
INSUFFICIENT_FUNDS_ERROR_KEY,
TRANSACTION_ERROR_KEY,
+ GAS_LIMIT_TOO_LOW_ERROR_KEY,
} from '../../helpers/constants/error-keys'
import { CONFIRMED_STATUS, DROPPED_STATUS } from '../../helpers/constants/transactions'
import UserPreferencedCurrencyDisplay from '../../components/app/user-preferenced-currency-display'
@@ -134,6 +135,7 @@ export default class ConfirmTransactionBase extends Component {
value: amount,
} = {},
} = {},
+ customGas,
} = this.props
const insufficientBalance = balance && !isBalanceSufficient({
@@ -150,6 +152,13 @@ export default class ConfirmTransactionBase extends Component {
}
}
+ if (customGas.gasLimit < 21000) {
+ return {
+ valid: false,
+ errorKey: GAS_LIMIT_TOO_LOW_ERROR_KEY,
+ }
+ }
+
if (simulationFails) {
return {
valid: true,