diff --git a/rsconcept/frontend/src/features/home/home-page.tsx b/rsconcept/frontend/src/features/home/home-page.tsx index 1776de2a..a1b161d7 100644 --- a/rsconcept/frontend/src/features/home/home-page.tsx +++ b/rsconcept/frontend/src/features/home/home-page.tsx @@ -1,14 +1,17 @@ import { urls, useConceptNavigation } from '@/app'; import { useAuthSuspense } from '@/features/auth'; +import { PARAMETER } from '@/utils/constants'; + export function HomePage() { const router = useConceptNavigation(); const { isAnonymous } = useAuthSuspense(); if (isAnonymous) { - router.replace({ path: urls.manuals }); + // Note: Timeout is needed to let router initialize + setTimeout(() => router.replace({ path: urls.login }), PARAMETER.minimalTimeout); } else { - router.replace({ path: urls.library }); + setTimeout(() => router.replace({ path: urls.library }), PARAMETER.minimalTimeout); } return null;