From 8e128fc64409418ff032f72b6d47c2b23a87ec16 Mon Sep 17 00:00:00 2001 From: Bernhard Schussek Date: Thu, 24 May 2012 08:54:17 +0200 Subject: [PATCH] [Form][OptionsResolver] Fixed typos --- UPGRADE-2.1.md | 2 +- .../Extension/Validator/Type/FormTypeValidatorExtension.php | 4 +++- src/Symfony/Component/OptionsResolver/README.md | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/UPGRADE-2.1.md b/UPGRADE-2.1.md index 236aa76419..373b61659c 100644 --- a/UPGRADE-2.1.md +++ b/UPGRADE-2.1.md @@ -643,7 +643,7 @@ ``` public function buildForm(FormBuilderInterface $builder, array $options) public function buildView(FormViewInterface $view, FormInterface $form, array $options) - public function buildViewBottomUp(FormViewInterface $view, FormInterface $form, array $options) + public function finishView(FormViewInterface $view, FormInterface $form, array $options) ``` * The following methods in `FormBuilder` were deprecated and have a new equivalent: diff --git a/src/Symfony/Component/Form/Extension/Validator/Type/FormTypeValidatorExtension.php b/src/Symfony/Component/Form/Extension/Validator/Type/FormTypeValidatorExtension.php index 53edf890ca..4b48760224 100644 --- a/src/Symfony/Component/Form/Extension/Validator/Type/FormTypeValidatorExtension.php +++ b/src/Symfony/Component/Form/Extension/Validator/Type/FormTypeValidatorExtension.php @@ -62,7 +62,9 @@ class FormTypeValidatorExtension extends AbstractTypeExtension $validationGroupsFilter = function (Options $options, $groups) { if (empty($groups)) { return null; - } elseif (is_callable($groups)) { + } + + if (is_callable($groups)) { return $groups; } diff --git a/src/Symfony/Component/OptionsResolver/README.md b/src/Symfony/Component/OptionsResolver/README.md index 94ffb4c85c..84a87787b5 100644 --- a/src/Symfony/Component/OptionsResolver/README.md +++ b/src/Symfony/Component/OptionsResolver/README.md @@ -85,7 +85,7 @@ method: )); $resolver->setDefaults(array( - // $previousValue contains the default value setDefaultOptionsd in the + // $previousValue contains the default value configured in the // parent class 'age' => function (Options $options, $previousValue) { return self::calculateAge($options['birthDate']);