From f7abdb2f472c2d488ac1fa75c5757e566b7d3a98 Mon Sep 17 00:00:00 2001 From: Mihaly Lengyel Date: Wed, 18 Dec 2024 00:38:20 +0100 Subject: [PATCH] feat: experiment with forceRefresh to use in impersonation --- lib/build/oauth2providerprebuiltui.js | 2 +- .../oauth2provider/components/features/tryRefreshPage/index.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/build/oauth2providerprebuiltui.js b/lib/build/oauth2providerprebuiltui.js index 445134aa0..1a058562f 100644 --- a/lib/build/oauth2providerprebuiltui.js +++ b/lib/build/oauth2providerprebuiltui.js @@ -368,7 +368,7 @@ var TryRefreshPage$1 = function (props) { switch (_a.label) { case 0: document.cookie = - "st-last-access-token-update=;expires=Thu, 01 Jan 1970 00:00:00 GMT"; + "st-last-access-token-update=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT"; if (!forceRefresh) return [3 /*break*/, 2]; return [4 /*yield*/, session.attemptRefreshingSession()]; case 1: diff --git a/lib/ts/recipe/oauth2provider/components/features/tryRefreshPage/index.tsx b/lib/ts/recipe/oauth2provider/components/features/tryRefreshPage/index.tsx index c5f0479e2..0c3486cba 100644 --- a/lib/ts/recipe/oauth2provider/components/features/tryRefreshPage/index.tsx +++ b/lib/ts/recipe/oauth2provider/components/features/tryRefreshPage/index.tsx @@ -51,7 +51,7 @@ export const TryRefreshPage: React.FC = (props) => { React.useEffect(() => { if (sessionContext.loading === false) { (async function () { - document.cookie = "st-last-access-token-update=;expires=Thu, 01 Jan 1970 00:00:00 GMT"; + document.cookie = "st-last-access-token-update=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT"; if (forceRefresh) { await attemptRefreshingSession(); }