Compare commits

..

No commits in common. "bd2f1e6e86d2f0665b9d31b00480d076532cd79d" and "8391d4083e0f785f5aaa240adb60603a93a03c5c" have entirely different histories.

1 changed files with 4 additions and 4 deletions

View File

@ -31,10 +31,10 @@ Chapar.interceptors.response.use(
// Do something with response error
// ;
// if (error.response.status === 401) {
// localStorage.removeItem("token");
// window.location.href = "/login";
// }
if (error.response.status === 401) {
localStorage.removeItem("token");
window.location.href = "/login";
}
return Promise.reject({ error, status: error?.response?.status });
}