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

[Form] Applying bug #18935 fix (done only on symfony/form) #20960

Closed
wants to merge 1 commit into from
Closed

[Form] Applying bug #18935 fix (done only on symfony/form) #20960

wants to merge 1 commit into from

Conversation

Ghriim
Copy link

@Ghriim Ghriim commented Dec 16, 2016

Q A
Branch? 3.2
Bug fix? yes
New feature? no
BC breaks? yes (only for the behavior)
Deprecations? no
Tests pass? yes
Fixed tickets symfony/form #11493
License MIT
Doc PR see symfony/form@8502f30)

@HeahDude
Copy link
Contributor

This is a duplicate of #18935 which has been reverted.

Sadly we cannot afford this bc break, prepopulating data in a form does not belong to the scope of its validation if it is not submitted.

Btw, calling $form->isValid() without calling $form->isSubmitted() first has been deprecated in 3.2, so this can be more consistant.

@fabpot fabpot closed this Dec 16, 2016
@Ghriim
Copy link
Author

Ghriim commented Dec 16, 2016

I've discover this bug fix from this ticket #11493
Is their any work around for PATCH context if the fix on ViolationMapper is finally reverted ?

@HeahDude
Copy link
Contributor

@Ghriim $this->get('validator')->validate($form->getData()) should be enough to avoid persisting wrong data ;), but you'll have to handle errors yourself though.

@xabbuh
Copy link
Member

xabbuh commented Feb 15, 2019

Can you confirm that the changes proposed in #30265 will fix this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants