Skip to content

Commit 1928678

Browse files
authored
Update axios.ts
1 parent a11ba63 commit 1928678

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugins/axios.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const axios: Plugin = ({$axios, redirect, $auth, app}) => {
1717
},
1818
async (error) => {
1919
const status = parseInt(error.response && error.response.status);
20-
const shouldRefresh = [401, 403].includes(code);
20+
const shouldRefresh = [401, 403].includes(status);
2121
if (shouldRefresh) {
2222
await $auth.logout();
2323
}

0 commit comments

Comments
 (0)