Skip to content

[Form] [Validator] Form validation not working with 2.5 api #11568

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

Closed
hlecorche opened this issue Aug 5, 2014 · 5 comments
Closed

[Form] [Validator] Form validation not working with 2.5 api #11568

hlecorche opened this issue Aug 5, 2014 · 5 comments

Comments

@hlecorche
Copy link
Contributor

With SF 2.5.3-DEV (commit 98c0621), if framework.validation.api = 2.5, all form validations throw BadMethodCallException :

validate() is not supported anymore as of Symfony 2.5. Please use getValidator() instead or enable the legacy mode.

Eg: In AcmeDemoBundle, contact action (_demo_contact route name) throws this exception.
But it works with SF 2.5.2.

@webmozart
Copy link
Contributor

Thanks Hubert for reporting this issue! I fixed it in the referenced PR.

@hlecorche
Copy link
Contributor Author

Thanks Bernhard 👍

@peterrehm
Copy link
Contributor

@fabpot I think with the many Form/Validator fixes a new stable release would be great.

@fabpot
Copy link
Member

fabpot commented Aug 6, 2014

@peterrehm The plan is to make a release today.

fabpot added a commit that referenced this issue Aug 6, 2014
….5 Validation API (webmozart)

This PR was merged into the 2.5 branch.

Discussion
----------

[Form] Fixed FormValidator compatibility with the non-BC 2.5 Validation API

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #11568
| License       | MIT
| Doc PR        | -

Commits
-------

6ac130e [Form] Fixed FormValidator compatibility with the non-BC 2.5 Validation API
@fabpot fabpot closed this as completed Aug 6, 2014
@peterrehm
Copy link
Contributor

Great, thanks.

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