Clone transaction while editing instead of mutating object from state.

feature/default_network_editable
Dan 7 years ago committed by Chi Kei Chan
parent 9ced63584b
commit e7e1b7a951
  1. 13
      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) {

Loading…
Cancel
Save