Skip to content

Commit

Permalink
refactor: rm version check in receiveStorageSubmission
Browse files Browse the repository at this point in the history
  • Loading branch information
LinHuiqing committed Sep 20, 2023
1 parent d7f5bca commit 69ce359
Showing 1 changed file with 1 addition and 15 deletions.
16 changes: 1 addition & 15 deletions src/app/modules/submission/receiver/receiver.middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,22 +52,8 @@ export const receiveEmailSubmission: ControllerHandler<
export const receiveStorageSubmission: ControllerHandler<
unknown,
{ message: string },
{ responses: FieldResponse[]; version: number }
{ responses: FieldResponse[] }
> = async (req, res, next) => {
if (req.body.version >= 2.1) {
const logMeta = {
action: 'receiveSubmission',
...createReqMeta(req),
}

logger.info({
message: 'Skipping multipart receiver since storage submission v2.1+',
meta: logMeta,
})

return next()
}

return receiveSubmission(
req,
res,
Expand Down

0 comments on commit 69ce359

Please sign in to comment.