diff --git a/src/_context/AuthenticationContext.tsx b/src/_context/AuthenticationContext.tsx index b44af9f8..d9d873ad 100644 --- a/src/_context/AuthenticationContext.tsx +++ b/src/_context/AuthenticationContext.tsx @@ -47,6 +47,7 @@ const AuthenticationProvider: FC = ({ children }) => { const logout = useCallback(async () => { try { await client.credentialsManager.clearCredentials(); + await client.webAuth.clearSession(); // Clear react query cache const queryCache = new QueryCache({}); @@ -61,7 +62,7 @@ const AuthenticationProvider: FC = ({ children }) => { } catch (e) { log.error(e); } - }, [client.credentialsManager, setIsAuthenticated]); + }, [client.credentialsManager, client.webAuth, setIsAuthenticated]); const checkAndRenewCredentials = useCallback(async () => { if (!client) return; diff --git a/src/login/Login.tsx b/src/login/Login.tsx index 2f953bcc..7ec76bdf 100644 --- a/src/login/Login.tsx +++ b/src/login/Login.tsx @@ -37,7 +37,6 @@ const Login = () => { { audience: Config.REACT_NATIVE_APP_AUTH0_AUDIENCE, product_display_name: 'UiTPAS', - prompt: 'login', referrer: 'uitpas', scope: 'openid profile email offline_access', },