Skip to content

Commit

Permalink
Revert logout on window unload in online survey app
Browse files Browse the repository at this point in the history
  • Loading branch information
esurface committed Jul 16, 2024
1 parent 5beca6b commit f82f70c
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions online-survey-app/src/app/app.component.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Component, OnInit, HostListener } from '@angular/core';
import { Component, OnInit } from '@angular/core';
import { AppConfigService } from './shared/_services/app-config.service';
import { _TRANSLATE } from './shared/_services/translation-marker';
import { AuthenticationService } from './core/auth/_services/authentication.service';
Expand Down Expand Up @@ -85,10 +85,4 @@ export class AppComponent implements OnInit{
this.loggedIn = false;
this.router.navigate(['/survey-login']);
}

@HostListener("window:unload",["$event"])
async onUnload(event) {
clearInterval(this.sessionTimeoutCheckTimerID);
await this.authenticationService.logout();
}
}

0 comments on commit f82f70c

Please sign in to comment.