diff --git a/npm/ng-packs/packages/core/src/lib/services/auth.service.ts b/npm/ng-packs/packages/core/src/lib/services/auth.service.ts index 752721e41a..3a1dadc4cb 100644 --- a/npm/ng-packs/packages/core/src/lib/services/auth.service.ts +++ b/npm/ng-packs/packages/core/src/lib/services/auth.service.ts @@ -41,8 +41,8 @@ export class AuthService { .toPromise(); } - logout(): Observable { - return this.strategy.logout(); + logout(queryParams?: Params): Observable { + return this.strategy.logout(queryParams); } /** diff --git a/npm/ng-packs/packages/core/src/lib/strategies/auth-flow.strategy.ts b/npm/ng-packs/packages/core/src/lib/strategies/auth-flow.strategy.ts index 1d79311f9c..8594e44bca 100644 --- a/npm/ng-packs/packages/core/src/lib/strategies/auth-flow.strategy.ts +++ b/npm/ng-packs/packages/core/src/lib/strategies/auth-flow.strategy.ts @@ -40,7 +40,7 @@ export abstract class AuthFlowStrategy { abstract checkIfInternalAuth(): boolean; abstract navigateToLogin(queryParams?: Params): void; - abstract logout(): Observable; + abstract logout(queryParams?: Params): Observable; abstract login(params?: LoginParams): Observable; private catchError = err => this.store.dispatch(new RestOccurError(err)); @@ -115,8 +115,8 @@ export class AuthCodeFlowStrategy extends AuthFlowStrategy { return false; } - logout() { - return from(this.oAuthService.revokeTokenAndLogout()); + logout(queryParams?: Params) { + return from(this.oAuthService.revokeTokenAndLogout(queryParams)); } login() { @@ -203,10 +203,10 @@ export class AuthPasswordFlowStrategy extends AuthFlowStrategy { ); } - logout() { + logout(queryParams?: Params) { const router = this.injector.get(Router); - return from(this.oAuthService.revokeTokenAndLogout()).pipe( + return from(this.oAuthService.revokeTokenAndLogout(queryParams)).pipe( switchMap(() => this.appConfigService.get()), tap(res => { this.configState.setState(res);