fix changing wallet when a tab is selected

This commit is contained in:
Matias Alejo Garcia 2016-02-23 10:33:40 -03:00
commit 0dfcde57f3
2 changed files with 10 additions and 5 deletions

View file

@ -52,6 +52,10 @@ angular.module('copayApp.controllers').controller('walletHomeController', functi
var disableFocusListener = $rootScope.$on('Local/NewFocusedWallet', function() {
self.addr = null;
self.resetForm();
if (profileService.focusedClient) {
self.setAddress();
self.setSendFormInputs();
}
$log.debug('Cleaning WalletHome Instance');
lodash.each(self, function(v, k) {
@ -60,6 +64,7 @@ angular.module('copayApp.controllers').controller('walletHomeController', functi
self[k] = vanillaScope[k];
return;
}
if (k == 'isRateAvailable') return;
delete self[k];
});