diff --git a/index.html b/index.html index 0bff542ab..05e812042 100644 --- a/index.html +++ b/index.html @@ -25,7 +25,11 @@ Loading...
-
+
+ + Logging Out +
+
diff --git a/js/controllers/head.js b/js/controllers/head.js index 3a665d01e..559ddf422 100644 --- a/js/controllers/head.js +++ b/js/controllers/head.js @@ -13,6 +13,7 @@ angular.module('copayApp.controllers').controller('HeadController', function($sc }; $scope.signout = function() { + $rootScope.signingOut = true; controllerUtils.logout(); }; @@ -33,7 +34,7 @@ angular.module('copayApp.controllers').controller('HeadController', function($sc // Ensures a graceful disconnect window.onbeforeunload = function() { - controllerUtils.logout(); + $scope.signout(); }; $scope.$on('$destroy', function() { @@ -59,7 +60,7 @@ angular.module('copayApp.controllers').controller('HeadController', function($sc $scope.title = newTitle; }); $rootScope.$on('signout', function() { - controllerUtils.logout(); + $scope.signout(); }); } });