diff --git a/backend/config/management/commands/ta_index_channel_tags.py b/backend/config/management/commands/ta_index_channel_tabs.py similarity index 100% rename from backend/config/management/commands/ta_index_channel_tags.py rename to backend/config/management/commands/ta_index_channel_tabs.py diff --git a/frontend/src/pages/Login.tsx b/frontend/src/pages/Login.tsx index ce8934bf..d07c392e 100644 --- a/frontend/src/pages/Login.tsx +++ b/frontend/src/pages/Login.tsx @@ -14,7 +14,6 @@ const Login = () => { const [password, setPassword] = useState(''); const [saveLogin, setSaveLogin] = useState(false); const [waitingForBackend, setWaitingForBackend] = useState(false); - const [loggingIn, setLoggingIn] = useState(false); const [waitedCount, setWaitedCount] = useState(0); const [errorMessage, setErrorMessage] = useState(null); @@ -26,15 +25,17 @@ const Login = () => { } setErrorMessage(null); - setLoggingIn(true); + const loginResponse = await signIn(username, password, saveLogin); + const signedIn = loginResponse.status === 204; + if (signedIn) { navigate(Routes.Home); } else { const data = await loginResponse.json(); setErrorMessage(data?.error || 'Unknown Error'); - setLoggingIn(false); + navigate(Routes.Login); } }; @@ -139,7 +140,7 @@ const Login = () => { )} - {!waitingForBackend &&