diff --git a/js/services/controllerUtils.js b/js/services/controllerUtils.js index b371bd332..475a9adff 100644 --- a/js/services/controllerUtils.js +++ b/js/services/controllerUtils.js @@ -38,15 +38,9 @@ angular.module('copayApp.services') delete $rootScope['wallet']; delete $rootScope['iden']; - // Clear rootScope - for (var i in $rootScope) { - if (i.charAt(0) != '$') { - delete $rootScope[i]; - } - } - - $location.path('/'); - + // Go home reloading the application + var hashIndex = window.location.href.indexOf('#!/'); + window.location = window.location.href.substr(0, hashIndex); }); } };