From cf3703e8ab86a32e7259e1f340f8e19a634167cd Mon Sep 17 00:00:00 2001 From: Ivan Socolsky Date: Thu, 4 Sep 2014 11:22:08 -0300 Subject: [PATCH 1/3] Add explicit call to updateAddressList --- js/controllers/addresses.js | 2 ++ js/controllers/sidebar.js | 1 + 2 files changed, 3 insertions(+) diff --git a/js/controllers/addresses.js b/js/controllers/addresses.js index d53ff8ae1..f31c60f39 100644 --- a/js/controllers/addresses.js +++ b/js/controllers/addresses.js @@ -5,6 +5,8 @@ angular.module('copayApp.controllers').controller('AddressesController', $scope.loading = false; var w = $rootScope.wallet; + controllerUtils.updateAddressList(); + $scope.newAddr = function() { $scope.loading = true; w.generateAddress(null, function() { diff --git a/js/controllers/sidebar.js b/js/controllers/sidebar.js index 54fc3df8c..5a1fb1b21 100644 --- a/js/controllers/sidebar.js +++ b/js/controllers/sidebar.js @@ -37,6 +37,7 @@ angular.module('copayApp.controllers').controller('SidebarController', function( $scope.refresh = function() { var w = $rootScope.wallet; w.sendWalletReady(); + controllerUtils.updateAddressList(); if ($rootScope.addrInfos.length > 0) { controllerUtils.updateBalance(function() { $rootScope.$digest(); From eb59a7dce9859f24760feb45ccd8b090d375191f Mon Sep 17 00:00:00 2001 From: Ivan Socolsky Date: Thu, 4 Sep 2014 13:16:09 -0300 Subject: [PATCH 2/3] Refresh global addresses when joining --- js/controllers/copayers.js | 1 + 1 file changed, 1 insertion(+) diff --git a/js/controllers/copayers.js b/js/controllers/copayers.js index c34aca096..b14f3fd41 100644 --- a/js/controllers/copayers.js +++ b/js/controllers/copayers.js @@ -15,6 +15,7 @@ angular.module('copayApp.controllers').controller('CopayersController', } $scope.goToWallet = function() { + controllerUtils.updateGlobalAddresses(); $location.path('/receive'); }; From f9458aa4a13ffe1f4b6e1bfebd367f683ba0bda6 Mon Sep 17 00:00:00 2001 From: Ivan Socolsky Date: Thu, 4 Sep 2014 13:23:56 -0300 Subject: [PATCH 3/3] Remove unnecessary code --- js/controllers/addresses.js | 2 -- js/controllers/sidebar.js | 1 - 2 files changed, 3 deletions(-) diff --git a/js/controllers/addresses.js b/js/controllers/addresses.js index f31c60f39..d53ff8ae1 100644 --- a/js/controllers/addresses.js +++ b/js/controllers/addresses.js @@ -5,8 +5,6 @@ angular.module('copayApp.controllers').controller('AddressesController', $scope.loading = false; var w = $rootScope.wallet; - controllerUtils.updateAddressList(); - $scope.newAddr = function() { $scope.loading = true; w.generateAddress(null, function() { diff --git a/js/controllers/sidebar.js b/js/controllers/sidebar.js index 5a1fb1b21..54fc3df8c 100644 --- a/js/controllers/sidebar.js +++ b/js/controllers/sidebar.js @@ -37,7 +37,6 @@ angular.module('copayApp.controllers').controller('SidebarController', function( $scope.refresh = function() { var w = $rootScope.wallet; w.sendWalletReady(); - controllerUtils.updateAddressList(); if ($rootScope.addrInfos.length > 0) { controllerUtils.updateBalance(function() { $rootScope.$digest();