From 9b8b5f55a9221a21f3bc308f792a8810dade3ef6 Mon Sep 17 00:00:00 2001 From: Szymon Lesisz Date: Wed, 30 May 2018 16:23:21 +0200 Subject: [PATCH] set default gasLimit if data.length < 1 (estimateGasPrice) --- src/js/actions/SendFormActions.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/actions/SendFormActions.js b/src/js/actions/SendFormActions.js index 4ca2bb91..aca7959f 100644 --- a/src/js/actions/SendFormActions.js +++ b/src/js/actions/SendFormActions.js @@ -790,7 +790,7 @@ const estimateGasPrice = (): AsyncAction => { const re = /^[0-9A-Fa-f]+$/g; if (!re.test(requestedData)) { // to stop calculating - dispatch( onGasLimitChange(state.gasLimit) ); + dispatch( onGasLimitChange(requestedData.length > 0 ? state.gasLimit : network.defaultGasLimit.toString()) ); return; }