fix(auth): handle expired session sources before permissions
The previous fix only prioritized authStore inside the route guard, so an unauthenticated NextAuth session or a suppressed access-context 401 still collapsed into an empty permission set. Propagate both authentication signals before authorization so expired sessions consistently reauthenticate.
This commit is contained in:
@@ -657,7 +657,6 @@ export const SystemAdminPanel = () => {
|
||||
try {
|
||||
const adminResponse = await apiFetch(`${config.BACKEND_URL}/api/v1/admin/users/me`, {
|
||||
projectHeaderMode: "omit",
|
||||
skipAuthRedirect: true,
|
||||
});
|
||||
if (!adminResponse.ok) {
|
||||
if (!cancelled) {
|
||||
|
||||
Reference in New Issue
Block a user