diff --git a/frontend/src/components/RouteGuards.tsx b/frontend/src/components/RouteGuards.tsx
index d67a067..ff2b46f 100644
--- a/frontend/src/components/RouteGuards.tsx
+++ b/frontend/src/components/RouteGuards.tsx
@@ -15,7 +15,7 @@ export function ProtectedRoute({ children }: { children: React.ReactNode }) {
if (!isAuthenticated) {
// Save the intended location to redirect back after login
- return ;
+ return ;
}
return <>{children}>;
diff --git a/frontend/src/pages/Login.tsx b/frontend/src/pages/Login.tsx
index 1ff4eab..a9aa38e 100644
--- a/frontend/src/pages/Login.tsx
+++ b/frontend/src/pages/Login.tsx
@@ -36,17 +36,13 @@ export default function Login() {
setIsLoading(true);
setApiError(null);
try {
- // 1. Authenticate
const { data: authData } = await publicApi.post(endpoints.LOGIN, data);
- // 2. Fetch User Profile with the fresh token
- // We pass the header explicitly to avoid any race conditions with interceptors
const { data: userData } = await api.get(endpoints.ME, {
headers: { Authorization: `Bearer ${authData.access}` },
});
- // 3. Update store using the hook method
- await login(authData.access, userData);
+ login(authData.access, userData);
navigate(ROUTES.DRAWER);
} catch (err) {
diff --git a/frontend/src/pages/VerifyEmail.tsx b/frontend/src/pages/VerifyEmail.tsx
index 52d1557..3c0c3be 100644
--- a/frontend/src/pages/VerifyEmail.tsx
+++ b/frontend/src/pages/VerifyEmail.tsx
@@ -33,7 +33,6 @@ export default function VerifyEmail() {
type="button"
className="text-xs italic opacity-40 cursor-pointer underline"
onClick={() => window.close()}
- onKeyDown={(e) => e.key === "Enter" && window.close()}
>
You can close this window now.