-
Notifications
You must be signed in to change notification settings - Fork 238
Open
Description
Actual:
req.body = { status: 'Draft' }
Expected:
req.body = {}
Steps to Repo:
- Configure endpoint with this following doc:
export const patch = [(req, res, next) => { console.log(req.body); res.status(204).end(); }]; patch.apiDoc = { "x-express-openapi-disable-defaults-middleware": true, requestBody: { required: true, "application/json": { schema: { additionalProperties: false, properties: { status: { type: "string", default: "Draft", }, }, }, }, }, };
- Console log the request body after making a PATCH command
curl -X PATCH --data '{}' -H "content-type: application/json" http://localhost:8080/blah/1
Thoughts:
Metadata
Metadata
Assignees
Labels
No labels