Skip to content

Commit 5e32e8a

Browse files
pylebecqweaverryan
authored andcommitted
Fixed 'validation_constraint' deprecation
According to the class FormTypeValidatorExtension, the option 'validation_constraint' is now deprecated in favor of 'constraints'
1 parent 6b9ca63 commit 5e32e8a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

book/forms.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1543,7 +1543,7 @@ but here's a short example::
15431543

15441544
// create a form, no default values, pass in the constraint option
15451545
$form = $this->createFormBuilder(null, array(
1546-
'validation_constraint' => $collectionConstraint,
1546+
'constraints' => $collectionConstraint,
15471547
))->add('email', 'email')
15481548
// ...
15491549
;
@@ -1573,7 +1573,7 @@ method to specify the option::
15731573
));
15741574

15751575
$resolver->setDefaults(array(
1576-
'validation_constraint' => $collectionConstraint
1576+
'constraints' => $collectionConstraint
15771577
));
15781578
}
15791579
}

0 commit comments

Comments
 (0)