diff --git a/packages/next/server/web/spec-extension/response.ts b/packages/next/server/web/spec-extension/response.ts index 4cb0958b49ec1a9..dff46ef005c5afa 100644 --- a/packages/next/server/web/spec-extension/response.ts +++ b/packages/next/server/web/spec-extension/response.ts @@ -63,7 +63,7 @@ export class NextResponse extends Response { return this.cookie(name, '', { expires: new Date(1), path: '/', ...opts }) } - static json(body: BodyInit | null) { + static json(body: any) { return new NextResponse(JSON.stringify(body), { headers: { 'content-type': 'application/json' }, })