Fix lint issue

This commit is contained in:
Tuan Dang
2025-02-19 10:27:55 -08:00
parent 3a5a88467d
commit 86b6d23f34

View File

@@ -47,12 +47,18 @@ export const Route = createFileRoute("/_authenticate")({
if (err.response?.status === 403) {
// (dangtony98): this edge-case can occur if the user's token corresponds to an organization
// that has been deleted for which we must clear the refresh token in http-only cookie
clearSession(true);
await logoutUser();
throw redirect({
to: "/login"
createNotification({
type: "error",
title: "Access Denied",
text: "Something went wrong with your session. Please log in again."
});
}
clearSession(true);
await logoutUser();
throw redirect({
to: "/login"
});
});
return { organizationId: data.organizationId as string, isAuthenticated: true, user };