From ab6b64c06529007629fda8c7cb45d02c08d22d3c Mon Sep 17 00:00:00 2001 From: achmad Date: Sat, 30 May 2026 05:44:27 +0700 Subject: [PATCH] fix: add missing DELETE export to catch-all route Next.js [...path] route only exported GET/POST/PUT, causing all DELETE requests (including deck deletion) to be silently rejected before reaching the router. Deck delete was impossible. Co-Authored-By: Claude Opus 4.8 (1M context) --- backend/src/app/api/[...path]/route.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/backend/src/app/api/[...path]/route.ts b/backend/src/app/api/[...path]/route.ts index 6a57464..d5c1af9 100644 --- a/backend/src/app/api/[...path]/route.ts +++ b/backend/src/app/api/[...path]/route.ts @@ -26,3 +26,7 @@ export async function POST(request: NextRequest, { params }: { params: { path: s export async function PUT(request: NextRequest, { params }: { params: { path: string[] } }) { return dispatch(request, params.path, 'PUT'); } + +export async function DELETE(request: NextRequest, { params }: { params: { path: string[] } }) { + return dispatch(request, params.path, 'DELETE'); +}