console: fix issue to clear admin secret key on logout

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/8503
GitOrigin-RevId: 7f94a2da01001b1b295151aa41c2e456c120f972
This commit is contained in:
Sameer Kolhar 2023-03-31 14:49:02 +05:30 committed by hasura-bot
parent 004dedca83
commit 40921f20bc

View File

@ -13,6 +13,7 @@ import {
} from '../AppState'; } from '../AppState';
import { import {
ADMIN_SECRET_ERROR, ADMIN_SECRET_ERROR,
clearAdminSecretState,
UPDATE_DATA_HEADERS, UPDATE_DATA_HEADERS,
} from '@hasura/console-legacy-ce'; } from '@hasura/console-legacy-ce';
import { getFeaturesCompatibility } from '../../helpers/versionUtils'; import { getFeaturesCompatibility } from '../../helpers/versionUtils';
@ -425,6 +426,7 @@ const clearCollaboratorSignInState = () => {
removeHeaderFromLS(globals.collabLabel); removeHeaderFromLS(globals.collabLabel);
removeHeaderFromLS(globals.patLabel); removeHeaderFromLS(globals.patLabel);
clearPATState(); clearPATState();
clearAdminSecretState();
initLS(); initLS();
dispatch(push(`${globals.urlPrefix}/login`)); dispatch(push(`${globals.urlPrefix}/login`));
}) })