mirror of
https://github.com/inventree/InvenTree.git
synced 2026-04-25 04:23:33 +00:00
add frontend cookie removal of mfa trust (#11768)
This commit is contained in:
@@ -212,6 +212,10 @@ export const doLogout = async (navigate: NavigateFunction) => {
|
|||||||
await authApi(apiUrl(ApiEndpoints.auth_session), undefined, 'delete').catch(
|
await authApi(apiUrl(ApiEndpoints.auth_session), undefined, 'delete').catch(
|
||||||
() => {}
|
() => {}
|
||||||
);
|
);
|
||||||
|
// remove MFA token (mfa_trusted)
|
||||||
|
document.cookie =
|
||||||
|
'mfa_trusted=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;';
|
||||||
|
|
||||||
showLoginNotification({
|
showLoginNotification({
|
||||||
title: t`Logged Out`,
|
title: t`Logged Out`,
|
||||||
message: t`Successfully logged out`
|
message: t`Successfully logged out`
|
||||||
|
|||||||
Reference in New Issue
Block a user