更改token过期判断

This commit is contained in:
Rewrite0
2023-05-31 22:05:01 +08:00
parent 94d23a3f4d
commit 26a0a54bd5

View File

@@ -25,7 +25,8 @@ axios.interceptors.response.use(
detail,
};
if (error.detail === 'Not authenticated') {
/** token 过期 */
if (error.status === 401) {
const { auth } = useAuth();
auth.value = '';
}