fix go home problem

This commit is contained in:
Gabriel Bazán 2015-11-23 13:18:38 -03:00
commit 999c3e7d5d
2 changed files with 12 additions and 9 deletions

View file

@ -18,7 +18,7 @@ angular.module('copayApp.controllers').controller('disclaimerController',
if (err) { if (err) {
if (err == 'EEXISTS') { if (err == 'EEXISTS') {
storageService.getCopayDisclaimerFlag(function(val) { storageService.getCopayDisclaimerFlag(function(err, val) {
if (val) return go.walletHome(); if (val) return go.walletHome();
$scope.creatingProfile = false; $scope.creatingProfile = false;
}); });

View file

@ -1325,6 +1325,8 @@ angular.module('copayApp.controllers').controller('indexController', function($r
$rootScope.$on('Local/NewFocusedWallet', function() { $rootScope.$on('Local/NewFocusedWallet', function() {
self.setFocusedWallet(); self.setFocusedWallet();
self.updateTxHistory(); self.updateTxHistory();
storageService.getCopayDisclaimerFlag(function(err, val) {
if (val) go.walletHome();
storageService.getCleanAndScanAddresses(function(err, walletId) { storageService.getCleanAndScanAddresses(function(err, walletId) {
if (walletId && profileService.walletClients[walletId]) { if (walletId && profileService.walletClients[walletId]) {
$log.debug('Clear last address cache and Scan ', walletId); $log.debug('Clear last address cache and Scan ', walletId);
@ -1335,6 +1337,7 @@ angular.module('copayApp.controllers').controller('indexController', function($r
} }
}); });
}); });
});
$rootScope.$on('Local/SetTab', function(event, tab, reset) { $rootScope.$on('Local/SetTab', function(event, tab, reset) {
self.setTab(tab, reset); self.setTab(tab, reset);