aboutsummaryrefslogtreecommitdiffstats
path: root/sdnr/wt/odlux/framework/src/handlers/authenticationHandler.ts
diff options
context:
space:
mode:
Diffstat (limited to 'sdnr/wt/odlux/framework/src/handlers/authenticationHandler.ts')
-rw-r--r--sdnr/wt/odlux/framework/src/handlers/authenticationHandler.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/sdnr/wt/odlux/framework/src/handlers/authenticationHandler.ts b/sdnr/wt/odlux/framework/src/handlers/authenticationHandler.ts
index 5217bd414..1bcb43528 100644
--- a/sdnr/wt/odlux/framework/src/handlers/authenticationHandler.ts
+++ b/sdnr/wt/odlux/framework/src/handlers/authenticationHandler.ts
@@ -22,6 +22,8 @@ import { AuthPolicy, User } from '../models/authentication';
import { onLogin, onLogout } from '../services/applicationApi';
import { startWebsocketSession, endWebsocketSession } from '../services/notificationService';
+import { startUserSession, endUserSession } from '../services/userSessionService';
+import { getSettings } from '../services/settingsService';
export interface IAuthenticationState {
user?: User;
@@ -38,11 +40,11 @@ export const authenticationStateHandler: IActionHandler<IAuthenticationState> =
if (user) {
localStorage.setItem("userToken", user.toString());
- startWebsocketSession();
+ startUserSession(user);
onLogin();
} else {
localStorage.removeItem("userToken");
- endWebsocketSession();
+ endUserSession();
onLogout();
}