This commit is contained in:
Matias Alejo Garcia 2014-11-30 01:11:00 -03:00
parent 5e92ae96ac
commit 1eebaa4e94
3 changed files with 4 additions and 4 deletions

View File

@ -23,8 +23,7 @@ angular.module('copayApp.controllers').controller('HomeController', function($sc
return;
}
$rootScope.starting = true;
identityService.open(form.email.$modelValue, form.password.$modelValue, function(err) {
$rootScope.starting = false;
identityService.open(form.email.$modelValue, form.password.$modelValue, function(err, iden) {
if (err) {
copay.logger.warn(err);
if ((err.toString() || '').match('PNOTFOUND')) {

View File

@ -444,7 +444,8 @@ Identity.importFromFullJson = function(str, password, opts, cb) {
* @emits newWallet (walletId)
*/
Identity.prototype.bindWallet = function(w) {
this.wallets[w.getId()] = w;
var self = this;
self.wallets[w.getId()] = w;
log.debug('Binding wallet:' + w.getName());
w.on('txProposalsUpdated', function() {

View File

@ -83,7 +83,6 @@ angular.module('copayApp.services')
copay.Identity.open(opts, function(err, iden) {
if (err) return cb(err);
console.log('[identityService.js.95] LISTO OPEN!!'); //TODO
root.bind(iden);
iden.openWallets();
return cb();
@ -256,6 +255,7 @@ angular.module('copayApp.services')
copay.logger.debug('newWallet:', w.getName(), wid, iden.getLastFocusedWalletId());
root.installWalletHandlers(w);
if (wid == iden.getLastFocusedWalletId()) {
$rootScope.starting = false;
copay.logger.debug('GOT Focused wallet:', w.getName());
root.setFocusedWallet(w, true);
root.goWalletHome();