mirror of
https://gitee.com/dapppp/ruoyi-plus-vben5.git
synced 2026-03-17 16:12:01 +08:00
refactor: 登出接口Promise.all
This commit is contained in:
@@ -79,8 +79,8 @@ export const useAuthStore = defineStore('auth', () => {
|
|||||||
|
|
||||||
async function logout(redirect: boolean = true) {
|
async function logout(redirect: boolean = true) {
|
||||||
try {
|
try {
|
||||||
await seeConnectionClose();
|
// 这两个接口不依赖 不需要await sseClose
|
||||||
await doLogout();
|
await Promise.all([seeConnectionClose(), doLogout()]);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error(error);
|
console.error(error);
|
||||||
} finally {
|
} finally {
|
||||||
|
|||||||
Reference in New Issue
Block a user