瀏覽代碼

update

master
Alex Cheung 1 年之前
父節點
當前提交
0e295a39a9
共有 1 個文件被更改,包括 9 次插入5 次删除
  1. +9
    -5
      src/auth/index.js

+ 9
- 5
src/auth/index.js 查看文件

@@ -183,12 +183,20 @@ export const SetupAxiosInterceptors = () => {
// alert("登入驗證已過期,請重新登入。")
// }
// }

if (error.response.status === 500) {
// await dispatch(handleLogoutFunction());
// await navigate('/login');
// await window.location.reload();
}
if (localStorage.getItem("expiredAlertShown")) {
await dispatch(handleLogoutFunction());
await navigate('/login');
await window.location.reload();
}

// console.log(error)

} else {
@@ -197,11 +205,7 @@ export const SetupAxiosInterceptors = () => {
await navigate('/login');
// await window.location.reload();
}
if (error.response.status === 500) {
// await dispatch(handleLogoutFunction());
// await navigate('/login');
// await window.location.reload();
}
}

}


Loading…
取消
儲存