aboutsummaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorkumavis <aaron@kumavis.me>2016-02-11 03:47:05 +0800
committerkumavis <aaron@kumavis.me>2016-02-11 03:47:05 +0800
commit435179856ff148cc5c4c64680848f407b30587c3 (patch)
treeb49dfc06965e6855185289954aba45ce55d3ae62 /app
parent066996396ff0ec6a9f6724e1f6469a0bc67a07ca (diff)
downloadtangerine-wallet-browser-435179856ff148cc5c4c64680848f407b30587c3.tar
tangerine-wallet-browser-435179856ff148cc5c4c64680848f407b30587c3.tar.gz
tangerine-wallet-browser-435179856ff148cc5c4c64680848f407b30587c3.tar.bz2
tangerine-wallet-browser-435179856ff148cc5c4c64680848f407b30587c3.tar.lz
tangerine-wallet-browser-435179856ff148cc5c4c64680848f407b30587c3.tar.xz
tangerine-wallet-browser-435179856ff148cc5c4c64680848f407b30587c3.tar.zst
tangerine-wallet-browser-435179856ff148cc5c4c64680848f407b30587c3.zip
idmgmt - emit update on new tx
Diffstat (limited to 'app')
-rw-r--r--app/scripts/lib/idmgmt.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/app/scripts/lib/idmgmt.js b/app/scripts/lib/idmgmt.js
index 27d4e570f..7bc276041 100644
--- a/app/scripts/lib/idmgmt.js
+++ b/app/scripts/lib/idmgmt.js
@@ -97,7 +97,6 @@ function submitPassword(password, cb){
var state = _getState()
cb(null, state)
// trigger an update but dont wait for it
- console.log(self)
self.updateIdentities()
})
}
@@ -164,11 +163,7 @@ IdentityManager.prototype.updateIdentity = function(address, cb){
function getTxCount(address, cb){
provider.sendAsync(createPayload({
method: 'eth_getTransactionCount',
- // we actually want the pending txCount
- // but pending is broken in provider-engine
- // https://github.com/MetaMask/provider-engine/issues/11
- // params: [address, 'pending'],
- params: [address, 'latest'],
+ params: [address, 'pending'],
}), function(err, res){
if (err) return cb(err)
if (res.error) return cb(res.error)
@@ -205,6 +200,8 @@ function tryPassword(password, cb){
}
function addUnconfirmedTransaction(txParams, cb){
+ var self = this
+
var time = (new Date()).getTime()
var txId = createId()
unconfTxs[txId] = {
@@ -219,6 +216,9 @@ function addUnconfirmedTransaction(txParams, cb){
// otherwise we need to keep the cb around
// signTransaction(txId, cb)
unconfTxCbs[txId] = cb
+
+ // signal update
+ self._didUpdate()
}
// called from