mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-07 14:26:03 +00:00
feat: login and register page
This commit is contained in:
@@ -129,7 +129,13 @@ class HttpClient {
|
||||
|
||||
switch (status) {
|
||||
case 401:
|
||||
window.location.href = '/login';
|
||||
|
||||
console.log('401 error: ', errMessage, error.request);
|
||||
console.log('responseURL', error.request.responseURL)
|
||||
localStorage.removeItem('token');
|
||||
if (!error.request.responseURL.includes('/check-token')) {
|
||||
window.location.href = '/login';
|
||||
}
|
||||
break;
|
||||
case 403:
|
||||
console.error('Permission denied:', errMessage);
|
||||
|
||||
Reference in New Issue
Block a user