Hide hotelreservation route and contentPages

This commit is contained in:
Linus Flood
2024-09-19 14:45:21 +02:00
parent 05fc698b63
commit 1e64f8b6b6
2 changed files with 10 additions and 0 deletions

View File

@@ -23,6 +23,9 @@ export default async function ContentTypePage({
switch (params.contentType) {
case "content-page":
if (env.HIDE_FOR_NEXT_RELEASE) {
return notFound()
}
return <ContentPage />
case "loyalty-page":
return <LoyaltyPage />

View File

@@ -1,3 +1,7 @@
import { notFound } from "next/navigation"
import { env } from "@/env/server"
import styles from "./layout.module.css"
import { LangParams, LayoutArgs } from "@/types/params"
@@ -5,5 +9,8 @@ import { LangParams, LayoutArgs } from "@/types/params"
export default function HotelReservationLayout({
children,
}: React.PropsWithChildren<LayoutArgs<LangParams>>) {
if (env.HIDE_FOR_NEXT_RELEASE) {
return notFound()
}
return <div className={styles.layout}>{children}</div>
}