Skip to content

Commit

Permalink
fix(fix-request-body): add fix for '+json' ending
Browse files Browse the repository at this point in the history
  • Loading branch information
howiezhao authored Jun 27, 2024
1 parent c8d34f1 commit 9892bfe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/handlers/fix-request-body.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export function fixRequestBody<TReq = http.IncomingMessage>(
proxyReq.write(bodyData);
};

if (contentType && contentType.includes('application/json')) {
if (contentType && (contentType.includes('application/json') || contentType.endsWith('+json'))) {
writeBody(JSON.stringify(requestBody));
}

Expand Down

0 comments on commit 9892bfe

Please sign in to comment.