feat: implement root domain handling for nobat724.com to prevent city filtering

This commit is contained in:
hamed
2026-07-02 21:53:45 +03:30
parent e6b55c6bad
commit 79f7df2e4d
9 changed files with 196 additions and 24 deletions
+4 -4
View File
@@ -20,13 +20,13 @@ export async function generateMetadata() {
}
async function Specialties() {
const { matchedCity, matchedState } = await getStateInfo();
const { matchedCity, matchedState, isRoot } = await getStateInfo();
return (
<Layout name="/specialties">
<SpecialtiesPage
cityId={matchedCity?.id ?? null}
cityName={matchedCity?.name ?? null}
stateName={matchedState?.name ?? null}
cityId={isRoot ? null : (matchedCity?.id ?? null)}
cityName={isRoot ? null : (matchedCity?.name ?? null)}
stateName={isRoot ? null : (matchedState?.name ?? null)}
/>
</Layout>
);