aboutsummaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorKevin Serrano <kevgagser@gmail.com>2016-07-22 01:15:34 +0800
committerKevin Serrano <kevgagser@gmail.com>2016-07-22 01:15:34 +0800
commit4a9d5b1c258912acedd6f1e89fb632526d9c910b (patch)
treee8a35826a47995c7fb8a32e30950a304e7a3c1ab /app
parent491b9cddc5fe1a7d0899d29c9a53aa71f04b9b28 (diff)
downloadtangerine-wallet-browser-4a9d5b1c258912acedd6f1e89fb632526d9c910b.tar
tangerine-wallet-browser-4a9d5b1c258912acedd6f1e89fb632526d9c910b.tar.gz
tangerine-wallet-browser-4a9d5b1c258912acedd6f1e89fb632526d9c910b.tar.bz2
tangerine-wallet-browser-4a9d5b1c258912acedd6f1e89fb632526d9c910b.tar.lz
tangerine-wallet-browser-4a9d5b1c258912acedd6f1e89fb632526d9c910b.tar.xz
tangerine-wallet-browser-4a9d5b1c258912acedd6f1e89fb632526d9c910b.tar.zst
tangerine-wallet-browser-4a9d5b1c258912acedd6f1e89fb632526d9c910b.zip
Add data field to pass up parameters up to reducer.
Diffstat (limited to 'app')
-rw-r--r--app/scripts/lib/idStore.js4
-rw-r--r--app/scripts/metamask-controller.js7
2 files changed, 9 insertions, 2 deletions
diff --git a/app/scripts/lib/idStore.js b/app/scripts/lib/idStore.js
index 2c8e9108b..94aaad1d1 100644
--- a/app/scripts/lib/idStore.js
+++ b/app/scripts/lib/idStore.js
@@ -99,6 +99,8 @@ IdentityStore.prototype.getState = function () {
unconfMsgs: messageManager.unconfirmedMsgs(),
messages: messageManager.getMsgList(),
selectedAddress: configManager.getSelectedAccount(),
+ currentFiat: configManager.getCurrentFiat(),
+ currentConversion: configManager.getConversionRate(),
}))
}
@@ -199,7 +201,7 @@ IdentityStore.prototype.addUnconfirmedTransaction = function (txParams, onTxDone
time: time,
status: 'unconfirmed',
}
-
+
console.log('addUnconfirmedTransaction:', txData)
// keep the onTxDoneCb around for after approval/denial (requires user interaction)
diff --git a/app/scripts/metamask-controller.js b/app/scripts/metamask-controller.js
index bcf5203fe..1b3b69932 100644
--- a/app/scripts/metamask-controller.js
+++ b/app/scripts/metamask-controller.js
@@ -241,8 +241,13 @@ module.exports = class MetamaskController {
try {
this.configManager.setCurrentFiat(fiat)
this.configManager.setConversionRate()
+ const data = {
+ conversionRate: this.configManager.getConversionRate,
+ currentFiat: this.configManager.getCurrentFiat,
+ }
+ cb(data)
} catch (e) {
- cb(e)
+ cb(null,e)
}
}