diff --git a/src/stores/index.ts b/src/stores/index.ts index 319bd9d..c1dd227 100644 --- a/src/stores/index.ts +++ b/src/stores/index.ts @@ -80,11 +80,11 @@ export const useMainStore = defineStore({ try { const token = this.session.token; + await api.delete(`/auth/${token}`); this.$patch({ session: undefined, user: undefined, }); - await api.delete(`/auth/${token}`); } catch (error) { return false; } finally {