zjs_project 1 miesiąc temu
rodzic
commit
9269d20ba7
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      src/permission.ts

+ 1 - 1
src/permission.ts

@@ -25,7 +25,7 @@ const whiteList: string[] = [PageEnum.LOGIN, PageEnum.ERROR_403]
 // 检测店铺ID变化并刷新页面的函数
 function checkShopIdChange() {
     const currentShopId = getShopId();
-    if (shopId !== currentShopId && currentShopId !== '') {
+    if (shopId !== currentShopId && currentShopId && shopId) {
         console.log('检测到店铺ID变化:', shopId, '->', currentShopId);
         shopId = currentShopId;
         // 刷新页面以更新数据