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

allowBlank not documented in possible annotation parameter for QueryParam / RequesParam #992

Open
allan-simon opened this issue Mar 14, 2015 · 5 comments

Comments

@allan-simon
Copy link
Contributor

it seems to be something that has been added recently

I'm currently finishing an other PR , so if someone feel like adding it in the doc

@allan-simon
Copy link
Contributor Author

and actually it does not work as i would have naively expected
i.e if you put it alone , it let empty string as 'valid' , one has to put together with requirements=".+" to have the expected behaviour of "whatever as long as its not an empty string"

@lsmith77
Copy link
Member

@mosch
Copy link
Contributor

mosch commented Mar 16, 2015

@allan-simon sadly the regex validator does not work as expected. The RegexValidator ignores everything that is null or an empty string. What documentation can i add to complete this?

@allan-simon
Copy link
Contributor Author

@mosch , indeed I've seen this ticket on symfony symfony/symfony#10221 I haven't read the full thread but it seems the behaviour is "on purpose and symfony people are well aware of it" and dont plan to fix it , and seems some stuff will change in a far future with symfony/symfony#12312

I guess you can in documentation that allowBlank is the way to go as requirements has this edge base (i'm not a very fluent english speaker, so I can't help on how to phrase it nicely :/ )

@lsmith77
Copy link
Member

ping @webmozart

@lsmith77 lsmith77 added this to the 1.6.0 milestone Mar 22, 2015
@lsmith77 lsmith77 added the ready label Apr 10, 2015
@lsmith77 lsmith77 modified the milestones: 1.6.0, 1.7.0 May 12, 2015
@lsmith77 lsmith77 modified the milestones: 1.7, 1.6, 1.8.0 Jun 15, 2015
@lsmith77 lsmith77 removed the ready label Jul 10, 2015
@lsmith77 lsmith77 modified the milestones: 1.8, 1.7 Jul 10, 2015
@lsmith77 lsmith77 modified the milestones: 1.7, 1.8 Aug 9, 2015
@lsmith77 lsmith77 modified the milestones: 1.8, 1.7 Aug 9, 2015
@lsmith77 lsmith77 modified the milestones: 1.8, 2.0 Aug 29, 2015
@lsmith77 lsmith77 modified the milestone: 2.0 Nov 10, 2015
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

3 participants