Refactor FeedbackPage component: Update props handling to ensure params are resolved as a Promise, aligning with Next.js 15 requirements and improving code clarity.
All checks were successful
Deploy with Docker Compose / deploy (push) Successful in 4m38s

This commit is contained in:
Julien Froidefond
2025-12-12 10:37:59 +01:00
parent f2805505a1
commit 5c06ec20a6

View File

@@ -4,14 +4,13 @@ import { getBackgroundImage } from "@/lib/preferences";
export const dynamic = "force-dynamic"; export const dynamic = "force-dynamic";
interface FeedbackPageProps { interface FeedbackPageProps {
params: { params: Promise<{
eventId: string; eventId: string;
}; }>;
} }
export default async function FeedbackPage({ export default async function FeedbackPage({ params }: FeedbackPageProps) {
params: _params, await params; // Ensure params are resolved (Next.js 15 requirement)
}: FeedbackPageProps) {
const backgroundImage = await getBackgroundImage("home", "/got-2.jpg"); const backgroundImage = await getBackgroundImage("home", "/got-2.jpg");
return <FeedbackPageClient backgroundImage={backgroundImage} />; return <FeedbackPageClient backgroundImage={backgroundImage} />;