From 0073b49a3831a09aea9e58c58f17335ae548cd5e Mon Sep 17 00:00:00 2001 From: Simon Date: Thu, 31 Jul 2025 22:16:37 +0700 Subject: [PATCH] fix typo, channel tabs not tags --- ...ta_index_channel_tags.py => ta_index_channel_tabs.py} | 0 frontend/src/pages/Login.tsx | 9 +++++---- 2 files changed, 5 insertions(+), 4 deletions(-) rename backend/config/management/commands/{ta_index_channel_tags.py => ta_index_channel_tabs.py} (100%) 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 &&