diff --git a/astro/src/pages/[...route].astro b/astro/src/pages/[...route].astro index 69cbb5e..277f2b4 100644 --- a/astro/src/pages/[...route].astro +++ b/astro/src/pages/[...route].astro @@ -25,7 +25,7 @@ export async function getStaticPaths() { } const settings = await getSettings(); -const pathName = Astro.url.pathname.replace(/\/$/, ""); +const pathName = Astro.url.pathname === "/" ? "/" : Astro.url.pathname.replace(/\/$/, ""); const page = await getPage(settings, pathName); console.log(pathName);