fix: resolve redirect logout uri problem

pull/5611/head
mehmet-erim 5 years ago
parent d4f106c832
commit f10503cd30

@ -119,7 +119,7 @@ export const AUTH_FLOW_STRATEGY = {
},
};
function clearOAuthStorage(storage: OAuthStorage) {
export function clearOAuthStorage(storage: OAuthStorage = oAuthStorage) {
const keys = [
'access_token',
'id_token',

@ -7,6 +7,7 @@ import { GetAppConfiguration } from '../actions/config.actions';
import { ABP } from '../models/common';
import { AuthService } from '../services/auth.service';
import { ConfigState } from '../states/config.state';
import { clearOAuthStorage } from '../strategies/auth-flow.strategy';
import { CORE_OPTIONS } from '../tokens/options.token';
import { getRemoteEnv } from './environment-utils';
import { parseTenantFromUrl } from './multi-tenancy-utils';
@ -34,7 +35,7 @@ export function getInitialData(injector: Injector) {
export function checkAccessToken(store: Store, injector: Injector) {
const oAuth = injector.get(OAuthService);
if (oAuth.hasValidAccessToken() && !store.selectSnapshot(ConfigState.getDeep('currentUser.id'))) {
oAuth.logOut();
clearOAuthStorage();
}
}

Loading…
Cancel
Save