mirror of
https://github.com/directus/directus.git
synced 2026-01-27 06:18:23 -05:00
Catch logout error (#17139)
This commit is contained in:
@@ -170,7 +170,11 @@ export async function logout(optionsRaw: LogoutOptions = {}): Promise<void> {
|
||||
|
||||
// Only if the user manually signed out should we kill the session by hitting the logout endpoint
|
||||
if (options.reason === LogoutReason.SIGN_OUT) {
|
||||
await api.post(`/auth/logout`);
|
||||
try {
|
||||
await api.post(`/auth/logout`);
|
||||
} catch {
|
||||
// User already signed out
|
||||
}
|
||||
}
|
||||
|
||||
appStore.authenticated = false;
|
||||
|
||||
Reference in New Issue
Block a user