symfony/symfony — Issue #2505: [Validator] DelegatingValidator buildFormPathMapping should be case insensitive
Author: drm
Created: 2011-10-28 10:12:45+00:00
State: open

The DelegatingValidator can not determine the path to elements that start with an uppercase letter. Because of this, form errors that occur in elements that start with an uppercase letter always bubble up to the root.

This is fixed by having the regexes in DelegatingValidator be case insensitive. I have currently no time to write a test for this, but if you would like me to, please let me know so I can do so this weekend.

The regexes are on [L158](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Extension/Validator/Validator/DelegatingValidator.php#L158), [L185](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Extension/Validator/Validator/DelegatingValidator.php#L185), [L193](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Extension/Validator/Validator/DelegatingValidator.php#L193), [L226](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Form/Extension/Validator/Validator/DelegatingValidator.php#L226)

I will issue a pull request for this.