Skip to content
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

Do not show "Requirement" when empty #502

Closed
JeroenDeDauw opened this issue Aug 31, 2014 · 4 comments
Closed

Do not show "Requirement" when empty #502

JeroenDeDauw opened this issue Aug 31, 2014 · 4 comments

Comments

@JeroenDeDauw
Copy link
Contributor

For the third filter here, no requirement has been defined. Can in such a case the requirement line be omitted?

requirement

The filters are defines as follows:

 * @QueryParam(name="page", default="1", requirements="[1-9][0-9]{0,1}", description="Specifies the page in the result set")
 * @QueryParam(name="per_page", default="100", requirements="[1-9][0-9]{0,2}", description="The maximum number of items to receive per page")
 * @QueryParam(name="type", nullable=true, description="Only show items of this type.")
@willdurand
Copy link
Collaborator

👍 would you mind come up with a patch?

@JeroenDeDauw
Copy link
Contributor Author

Sure. Before I opened this I spend 15 minutes on trying to find where this is created and failed. I did not find any code containing the "Requirement" string that got executed. Is there some caching going on?

@Khez
Copy link

Khez commented Sep 8, 2014

@willdurand Should this be configurable? Hardcore requirements ? Or just ignore all empty sections ? Wouldn't mind doing this PR :)

dpcat237 added a commit to dpcat237/NelmioApiDocBundle that referenced this issue Jun 12, 2016
dpcat237 added a commit to dpcat237/NelmioApiDocBundle that referenced this issue Jun 12, 2016
willdurand added a commit that referenced this issue Jun 13, 2016
@dbu
Copy link
Collaborator

dbu commented Dec 22, 2017

version 3 is a complete rewrite. please check if this is still a problem with version 3 and a recent symfony version.

@dbu dbu closed this as completed Dec 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants