From e7e1b7a95180597308bd167bd4a152bbbf53ff21 Mon Sep 17 00:00:00 2001 From: Dan Date: Wed, 20 Dec 2017 19:11:18 -0330 Subject: [PATCH] Clone transaction while editing instead of mutating object from state. --- ui/app/send-v2.js | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/ui/app/send-v2.js b/ui/app/send-v2.js index cf9e709d4..b7f2e7277 100644 --- a/ui/app/send-v2.js +++ b/ui/app/send-v2.js @@ -566,12 +566,13 @@ SendTransactionScreen.prototype.getEditedTx = function () { unapprovedTxs, } = this.props - const editingTx = unapprovedTxs[editingTransactionId] - - editingTx.txParams = { - from: ethUtil.addHexPrefix(from), - gas: ethUtil.addHexPrefix(gas), - gasPrice: ethUtil.addHexPrefix(gasPrice), + const editingTx = { + ...unapprovedTxs[editingTransactionId], + txParams: { + from: ethUtil.addHexPrefix(from), + gas: ethUtil.addHexPrefix(gas), + gasPrice: ethUtil.addHexPrefix(gasPrice), + } } if (selectedToken) {