diff --git a/app/controllers/errorPageController.js b/app/controllers/errorPageController.js index 02ef85b..908a49d 100644 --- a/app/controllers/errorPageController.js +++ b/app/controllers/errorPageController.js @@ -1,25 +1,25 @@ core.controller("ErrorPageController", function ($scope, AccessControlService) { - $scope.getPath = function (path) { + $scope.getPath = function (path) { - if (!!path && path.length > 0) { - var paths = path.split('/'); + if (!!path && path.length > 0) { + var paths = path.split('/'); - for (var i in paths) { - // Return to top-level when previous path contains route variables. - if (paths[i][0] === ':') { - paths = []; - break; - } + for (var i in paths) { + // Return to top-level when previous path contains route variables. + if (paths[i][0] === ':') { + paths = []; + break; } - - return paths.join('/'); } - return path; - }; + return paths.join('/'); + } + + return path; + }; - // This is actually a URL path and not a route. - $scope.lastRoute = $scope.getPath(AccessControlService.getLastRoutePath()); + // This is actually a URL path and not a route. + $scope.lastRoute = $scope.getPath(AccessControlService.getLastRoutePath()); });