fix: await params in Next.js 16 routes and pages for TypeScript compatibility

This commit is contained in:
2026-03-31 00:50:56 -07:00
parent 42217e182e
commit b8d90897a4
13 changed files with 85 additions and 32 deletions
@@ -12,7 +12,9 @@ interface PageProps {
}
export default async function TournamentResultsPage({ params }: PageProps) {
const tournamentId = parseInt(params.id, 10)
// Next.js 16 requires awaiting params
const { id } = await params
const tournamentId = parseInt(id, 10)
if (isNaN(tournamentId)) {
notFound()