aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan <danjm.com@gmail.com>2018-03-15 03:40:59 +0800
committerDan <danjm.com@gmail.com>2018-03-15 03:40:59 +0800
commita4c6a5e92e09b70db2e9ab92a8123176de127910 (patch)
tree914d04e05b134fea8cc63b9f8e6f878f5951e17b
parentfb838da7340d460650750cb8ea5fa3fb6fe319de (diff)
downloadtangerine-wallet-browser-a4c6a5e92e09b70db2e9ab92a8123176de127910.tar
tangerine-wallet-browser-a4c6a5e92e09b70db2e9ab92a8123176de127910.tar.gz
tangerine-wallet-browser-a4c6a5e92e09b70db2e9ab92a8123176de127910.tar.bz2
tangerine-wallet-browser-a4c6a5e92e09b70db2e9ab92a8123176de127910.tar.lz
tangerine-wallet-browser-a4c6a5e92e09b70db2e9ab92a8123176de127910.tar.xz
tangerine-wallet-browser-a4c6a5e92e09b70db2e9ab92a8123176de127910.tar.zst
tangerine-wallet-browser-a4c6a5e92e09b70db2e9ab92a8123176de127910.zip
Ensure changes from customize gas modal opened from confirm screen are captured for non-tx transactions.
-rw-r--r--ui/app/components/pending-tx/confirm-send-ether.js10
-rw-r--r--ui/app/components/pending-tx/confirm-send-token.js10
2 files changed, 8 insertions, 12 deletions
diff --git a/ui/app/components/pending-tx/confirm-send-ether.js b/ui/app/components/pending-tx/confirm-send-ether.js
index 9b9a4e4ea..928149ccd 100644
--- a/ui/app/components/pending-tx/confirm-send-ether.js
+++ b/ui/app/components/pending-tx/confirm-send-ether.js
@@ -494,13 +494,11 @@ ConfirmSendEther.prototype.gatherTxMeta = function () {
const state = this.state
const txData = clone(state.txData) || clone(props.txData)
- if (txData.lastGasPrice) {
- const { gasPrice: sendGasPrice, gas: sendGasLimit } = props.send
- const { gasPrice: txGasPrice, gas: txGasLimit } = txData.txParams
+ const { gasPrice: sendGasPrice, gas: sendGasLimit } = props.send
+ const { gasPrice: txGasPrice, gas: txGasLimit } = txData.txParams
- txData.txParams.gasPrice = sendGasPrice || txGasPrice
- txData.txParams.gas = sendGasLimit || txGasLimit
- }
+ txData.txParams.gasPrice = sendGasPrice || txGasPrice
+ txData.txParams.gas = sendGasLimit || txGasLimit
// log.debug(`UI has defaulted to tx meta ${JSON.stringify(txData)}`)
return txData
diff --git a/ui/app/components/pending-tx/confirm-send-token.js b/ui/app/components/pending-tx/confirm-send-token.js
index ac773b1d2..fe323ffd3 100644
--- a/ui/app/components/pending-tx/confirm-send-token.js
+++ b/ui/app/components/pending-tx/confirm-send-token.js
@@ -487,13 +487,11 @@ ConfirmSendToken.prototype.gatherTxMeta = function () {
const state = this.state
const txData = clone(state.txData) || clone(props.txData)
- if (txData.lastGasPrice) {
- const { gasPrice: sendGasPrice, gas: sendGasLimit } = props.send
- const { gasPrice: txGasPrice, gas: txGasLimit } = txData.txParams
+ const { gasPrice: sendGasPrice, gas: sendGasLimit } = props.send
+ const { gasPrice: txGasPrice, gas: txGasLimit } = txData.txParams
- txData.txParams.gasPrice = sendGasPrice || txGasPrice
- txData.txParams.gas = sendGasLimit || txGasLimit
- }
+ txData.txParams.gasPrice = sendGasPrice || txGasPrice
+ txData.txParams.gas = sendGasLimit || txGasLimit
// log.debug(`UI has defaulted to tx meta ${JSON.stringify(txData)}`)
return txData