Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[Validator] The PropertyInfoLoader should return early when disabled#32278
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
[Validator] The PropertyInfoLoader should return early when disabled#32278
Uh oh!
There was an error while loading.Please reload this page.
Conversation
| publicfunctionloadClassMetadata(ClassMetadata$metadata) | ||
| { | ||
| $className =$metadata->getClassName(); | ||
| if (null!==$this->classValidatorRegexp&& !preg_match($this->classValidatorRegexp,$className)) { |
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.
If null is passed, it means that it should be always executed IIRC.
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.
I don't think it should be the case, especially with:https://github.com/symfony/symfony/pull/31749/files#diff-0bd78268e7d70f726415dc3175eaa595R76
xabbuh commentedJun 30, 2019
I guess we need to investigate why the |
alanpoulain commentedJul 1, 2019
The code to remove the symfony/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php Lines 1263 to 1265 in835f6b0
You can see it's the case only when there is no auto-mapping configuration at all. |
fabpot commentedAug 20, 2020
fabpot commentedSep 1, 2020
Closing for now as it's not clear if this is the right change. |
Related to:#31749 anddoctrine/DoctrineBundle#988.
If the auto-mapping was partially enabled for one resource (the Doctrine one), then the property info loader was applied for all the resources.
For instance, considering this configuration:
If there is a
Barentity, then the loader is applied too.