diff --git a/TODO.md b/TODO.md index bff1853..ed05953 100644 --- a/TODO.md +++ b/TODO.md @@ -63,3 +63,27 @@ - All 84 unit tests passing - Database migrations applied successfully - TypeScript compilation has pre-existing errors unrelated to our changes + +### Completed After Commit 1729dac + +#### Next.js 16 Breaking Change Fixes +- [x] Fixed `params.id` usage in all page components (must use `await params`) +- [x] Fixed `params.id` usage in all API routes (must use `await params`) +- [x] Updated client components to use `Promise<{ id: string }>` type +- [x] Added regression tests for Next.js 16 params Promise handling +- [x] Verified all 100 unit tests pass + +#### Files Updated: +- Player pages: `profile.tsx`, `schedule.tsx` +- Tournament pages: `page.tsx`, `results.tsx`, `edit.tsx`, `entry.tsx` +- API routes: `admin/players/[id]/route.ts`, `users/[id]/route.ts`, `users/[id]/role/route.ts` +- Tournament API routes: `[id]/route.ts`, `[id]/participants/route.ts`, `[id]/games/bulk/route.ts` + +#### Root Cause +Next.js 16 requires `params` to be awaited in both server components and API routes: +- Before: `const { id } = params` +- After: `const { id } = await params` + +This was not caught by the unit test suite because: +- Unit tests test individual functions in isolation +- E2E tests (Playwright) would catch this but weren't run after the upgrade