From 9c217972e18130cd45b4b3dbf2c8bdb627d8a1b3 Mon Sep 17 00:00:00 2001 From: YunaiV Date: Mon, 21 Jul 2025 17:10:24 +0800 Subject: [PATCH] =?UTF-8?q?fix=EF=BC=9AuserInfo.permissions=20=E5=85=9C?= =?UTF-8?q?=E5=BA=95=E6=98=AF=E7=A9=BA=E6=83=85=E5=86=B5=E7=9A=84=E5=A4=84?= =?UTF-8?q?=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/store/modules/user.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/store/modules/user.ts b/src/store/modules/user.ts index 6876043e..aea2eda3 100644 --- a/src/store/modules/user.ts +++ b/src/store/modules/user.ts @@ -62,7 +62,7 @@ export const useUserStore = defineStore('admin-user', { userInfo = await getInfo() } catch (error) {} } - this.permissions = new Set(userInfo.permissions) + this.permissions = new Set(userInfo.permissions || []) // 兜底为 [] https://t.zsxq.com/xCJew this.roles = userInfo.roles this.user = userInfo.user this.isSetUser = true