fix(admin): correct 401 redirect path to include /admin prefix
The API interceptor was redirecting to /login on 401 errors, but since admin-client is deployed under /admin/, it should redirect to /admin/login. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
731323ad7c
commit
e6e69f15ce
|
|
@ -28,7 +28,7 @@ api.interceptors.response.use(
|
|||
(error) => {
|
||||
if (error.response?.status === 401) {
|
||||
localStorage.removeItem('admin_token');
|
||||
window.location.href = '/login';
|
||||
window.location.href = '/admin/login';
|
||||
}
|
||||
return Promise.reject(error);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue