Skip to content

Commit

Permalink
fix(define): don't camelize files
Browse files Browse the repository at this point in the history
  • Loading branch information
CompuIves committed Apr 11, 2024
1 parent f509c2d commit 3839fc2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/git-extractor/src/middleware/camelize.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,11 @@ import { camelizeKeys } from "humps";

const camelizeMiddleware = async (ctx: Context, next: () => Promise<any>) => {
if (ctx.request.body) {
const originalBody = ctx.request.body;
ctx.request.body = camelizeKeys(ctx.request.body);
if (ctx.request.body.files) {
ctx.request.body.files = originalBody.files;
}
}

await next();
Expand Down

0 comments on commit 3839fc2

Please sign in to comment.