diff options
author | Alexander Tseung <alextsg@users.noreply.github.com> | 2018-12-10 04:48:06 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-12-10 04:48:06 +0800 |
commit | d8ab9cc002c10757b7382a174dafff7a0247e307 (patch) | |
tree | d0a46ac3ca2334ddec2ee240214d67a8122e81b7 /ui/app/ducks | |
parent | 575fb607c3b8deea831aa28293303991b3f6be29 (diff) | |
download | tangerine-wallet-browser-d8ab9cc002c10757b7382a174dafff7a0247e307.tar.gz tangerine-wallet-browser-d8ab9cc002c10757b7382a174dafff7a0247e307.tar.zst tangerine-wallet-browser-d8ab9cc002c10757b7382a174dafff7a0247e307.zip |
Group transactions by nonce (#5886)
Diffstat (limited to 'ui/app/ducks')
-rw-r--r-- | ui/app/ducks/gas.duck.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/ui/app/ducks/gas.duck.js b/ui/app/ducks/gas.duck.js index 8db24cc83..83c236d81 100644 --- a/ui/app/ducks/gas.duck.js +++ b/ui/app/ducks/gas.duck.js @@ -4,6 +4,9 @@ import { loadLocalStorageData, saveLocalStorageData, } from '../../lib/local-storage-helpers' +import { + decGWEIToHexWEI, +} from '../helpers/conversions.util' // Actions const BASIC_GAS_ESTIMATE_LOADING_FINISHED = 'metamask/gas/BASIC_GAS_ESTIMATE_LOADING_FINISHED' @@ -403,6 +406,17 @@ export function fetchGasEstimates (blockTime) { } } +export function setCustomGasPriceForRetry (newPrice) { + return (dispatch) => { + if (newPrice !== '0x0') { + dispatch(setCustomGasPrice(newPrice)) + } else { + const { fast } = loadLocalStorageData('BASIC_PRICE_ESTIMATES') + dispatch(setCustomGasPrice(decGWEIToHexWEI(fast))) + } + } +} + export function setBasicGasEstimateData (basicGasEstimateData) { return { type: SET_BASIC_GAS_ESTIMATE_DATA, |