-
-
Notifications
You must be signed in to change notification settings - Fork 347
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: request bodies should take required property into account #1277
fix: request bodies should take required property into account #1277
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@AffeJonsson
Hi, Thank you for great PR, I commented on one consultation, so please check it.
@@ -0,0 +1,223 @@ | |||
openapi: '3.0.0' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We will continue to maintain the tests, so we would like to keep them to a minimum as much as possible. Is it possible to slim down to a minimized case that only checks the request body?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Absolutely, I'll fix!
I understand that in the specification it’s optional per default but 99% if you have a request body you want it required no? |
That's probably true. Maybe it would be better if it's required as default. I'll change that, but at least with this change it'll take the required prop into account |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you.
Status
READY
Description
Fixes #1111Takes the required property of request bodies into account. We till make it required by default, but setting it to required: false will make it optional.
Todos
Steps to Test or Reproduce