Skip to content

Commit

Permalink
fix(web): unable to redirect to login page (#821)
Browse files Browse the repository at this point in the history
  • Loading branch information
kongwy229 authored Feb 24, 2023
1 parent 0771b59 commit 33f7cb1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion web/src/utils/request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ request.interceptors.response.use(
const { data } = error.response;
if (data.statusCode === 401) {
// eslint-disable-next-line no-restricted-globals
// (window as any).location.href = (import.meta.env.VITE_SERVER_URL + "/v1/login") as string;
(window as any).location.href = (import.meta.env.VITE_SERVER_URL + "/v1/login") as string;
return;
} else if (data.statusCode === 403) {
(window as any).location.href = "/403";
Expand Down

0 comments on commit 33f7cb1

Please sign in to comment.