merged branch Tobion/patch-2 (PR #5240)
Commits
-------
9e5d5a4
[Form] fix static method call
Discussion
----------
[Form] fix static method call
`allowDataWalking` was called statically, but wasnt defined as such.
This commit is contained in:
commit
bef34bda67
@ -53,7 +53,7 @@ class FormValidator extends ConstraintValidator
|
|||||||
// Validate the form data only if transformation succeeded
|
// Validate the form data only if transformation succeeded
|
||||||
$path = $this->context->getPropertyPath();
|
$path = $this->context->getPropertyPath();
|
||||||
$graphWalker = $this->context->getGraphWalker();
|
$graphWalker = $this->context->getGraphWalker();
|
||||||
$groups = $this->getValidationGroups($form);
|
$groups = self::getValidationGroups($form);
|
||||||
|
|
||||||
if (!empty($path)) {
|
if (!empty($path)) {
|
||||||
$path .= '.';
|
$path .= '.';
|
||||||
@ -126,7 +126,7 @@ class FormValidator extends ConstraintValidator
|
|||||||
*
|
*
|
||||||
* @return Boolean Whether the graph walker may walk the data.
|
* @return Boolean Whether the graph walker may walk the data.
|
||||||
*/
|
*/
|
||||||
private function allowDataWalking(FormInterface $form)
|
private static function allowDataWalking(FormInterface $form)
|
||||||
{
|
{
|
||||||
$data = $form->getData();
|
$data = $form->getData();
|
||||||
|
|
||||||
@ -158,7 +158,7 @@ class FormValidator extends ConstraintValidator
|
|||||||
*
|
*
|
||||||
* @return array The validation groups.
|
* @return array The validation groups.
|
||||||
*/
|
*/
|
||||||
private function getValidationGroups(FormInterface $form)
|
private static function getValidationGroups(FormInterface $form)
|
||||||
{
|
{
|
||||||
do {
|
do {
|
||||||
$groups = $form->getConfig()->getOption('validation_groups');
|
$groups = $form->getConfig()->getOption('validation_groups');
|
||||||
|
Reference in New Issue
Block a user