summaryrefslogtreecommitdiffstats
path: root/app/index.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/index.js')
-rw-r--r--app/index.js9
1 files changed, 6 insertions, 3 deletions
diff --git a/app/index.js b/app/index.js
index eb27a34..57d031b 100644
--- a/app/index.js
+++ b/app/index.js
@@ -126,7 +126,7 @@ window.angular && (function(angular) {
// Dependencies
'ngRoute', 'angular-clipboard', 'ngToast', 'ngAnimate',
'ngMessages', 'app.common.directives.dirPagination', 'ngSanitize',
- 'ui.bootstrap',
+ 'ui.bootstrap', 'ngCookies',
// Basic resources
'app.common.services', 'app.common.directives',
'app.common.filters', 'app.common.components',
@@ -184,8 +184,8 @@ window.angular && (function(angular) {
}
])
.run([
- '$rootScope', '$location', 'dataService', 'userModel',
- function($rootScope, $location, dataService, userModel) {
+ '$rootScope', '$location', 'dataService', 'userModel', '$cookies',
+ function($rootScope, $location, dataService, userModel, $cookies) {
$rootScope.dataService = dataService;
dataService.path = $location.path();
$rootScope.$on('$routeChangeStart', function(event, next, current) {
@@ -219,7 +219,10 @@ window.angular && (function(angular) {
});
$rootScope.$on('timedout-user', function() {
+ console.log('timedout-user event triggered');
sessionStorage.removeItem('LOGIN_ID');
+ $cookies.remove('IsAuthenticated');
+
$location.path('/login');
});
}
OpenPOWER on IntegriCloud