From 3ac98a6a171810b152a51465919411df3054eed2 Mon Sep 17 00:00:00 2001 From: Robin Chalas Date: Fri, 28 Dec 2018 23:40:08 +0100 Subject: [PATCH] Revert "minor #28610 [Form] Check for Intl availibility (ro0NL)" This reverts commit 15aa25a1ed7ea6844d6f7873a39a143e3b4587ac, reversing changes made to 3cd411af3e5a0fb74a10f2fbb3575c180b6af1b2. --- .../Component/Form/Extension/Core/Type/CountryType.php | 5 ----- .../Component/Form/Extension/Core/Type/CurrencyType.php | 5 ----- .../Component/Form/Extension/Core/Type/LanguageType.php | 5 ----- .../Component/Form/Extension/Core/Type/LocaleType.php | 5 ----- 4 files changed, 20 deletions(-) diff --git a/src/Symfony/Component/Form/Extension/Core/Type/CountryType.php b/src/Symfony/Component/Form/Extension/Core/Type/CountryType.php index c3e381b7c6e61..195347bc9d250 100644 --- a/src/Symfony/Component/Form/Extension/Core/Type/CountryType.php +++ b/src/Symfony/Component/Form/Extension/Core/Type/CountryType.php @@ -15,7 +15,6 @@ use Symfony\Component\Form\ChoiceList\ArrayChoiceList; use Symfony\Component\Form\ChoiceList\Loader\ChoiceLoaderInterface; use Symfony\Component\Form\ChoiceList\Loader\IntlCallbackChoiceLoader; -use Symfony\Component\Form\Exception\LogicException; use Symfony\Component\Intl\Intl; use Symfony\Component\OptionsResolver\Options; use Symfony\Component\OptionsResolver\OptionsResolver; @@ -42,10 +41,6 @@ public function configureOptions(OptionsResolver $resolver) { $resolver->setDefaults(array( 'choice_loader' => function (Options $options) { - if (!class_exists(Intl::class)) { - throw new LogicException(sprintf('The "symfony/intl" component is required to use "%s".', static::class)); - } - $choiceTranslationLocale = $options['choice_translation_locale']; return new IntlCallbackChoiceLoader(function () use ($choiceTranslationLocale) { diff --git a/src/Symfony/Component/Form/Extension/Core/Type/CurrencyType.php b/src/Symfony/Component/Form/Extension/Core/Type/CurrencyType.php index 77ed33b23705a..4cf76eed58623 100644 --- a/src/Symfony/Component/Form/Extension/Core/Type/CurrencyType.php +++ b/src/Symfony/Component/Form/Extension/Core/Type/CurrencyType.php @@ -15,7 +15,6 @@ use Symfony\Component\Form\ChoiceList\ArrayChoiceList; use Symfony\Component\Form\ChoiceList\Loader\ChoiceLoaderInterface; use Symfony\Component\Form\ChoiceList\Loader\IntlCallbackChoiceLoader; -use Symfony\Component\Form\Exception\LogicException; use Symfony\Component\Intl\Intl; use Symfony\Component\OptionsResolver\Options; use Symfony\Component\OptionsResolver\OptionsResolver; @@ -42,10 +41,6 @@ public function configureOptions(OptionsResolver $resolver) { $resolver->setDefaults(array( 'choice_loader' => function (Options $options) { - if (!class_exists(Intl::class)) { - throw new LogicException(sprintf('The "symfony/intl" component is required to use "%s".', static::class)); - } - $choiceTranslationLocale = $options['choice_translation_locale']; return new IntlCallbackChoiceLoader(function () use ($choiceTranslationLocale) { diff --git a/src/Symfony/Component/Form/Extension/Core/Type/LanguageType.php b/src/Symfony/Component/Form/Extension/Core/Type/LanguageType.php index 4ddf80f151fac..56161563e33e7 100644 --- a/src/Symfony/Component/Form/Extension/Core/Type/LanguageType.php +++ b/src/Symfony/Component/Form/Extension/Core/Type/LanguageType.php @@ -15,7 +15,6 @@ use Symfony\Component\Form\ChoiceList\ArrayChoiceList; use Symfony\Component\Form\ChoiceList\Loader\ChoiceLoaderInterface; use Symfony\Component\Form\ChoiceList\Loader\IntlCallbackChoiceLoader; -use Symfony\Component\Form\Exception\LogicException; use Symfony\Component\Intl\Intl; use Symfony\Component\OptionsResolver\Options; use Symfony\Component\OptionsResolver\OptionsResolver; @@ -42,10 +41,6 @@ public function configureOptions(OptionsResolver $resolver) { $resolver->setDefaults(array( 'choice_loader' => function (Options $options) { - if (!class_exists(Intl::class)) { - throw new LogicException(sprintf('The "symfony/intl" component is required to use "%s".', static::class)); - } - $choiceTranslationLocale = $options['choice_translation_locale']; return new IntlCallbackChoiceLoader(function () use ($choiceTranslationLocale) { diff --git a/src/Symfony/Component/Form/Extension/Core/Type/LocaleType.php b/src/Symfony/Component/Form/Extension/Core/Type/LocaleType.php index 6516a692eca8f..ed8fe5d8401e5 100644 --- a/src/Symfony/Component/Form/Extension/Core/Type/LocaleType.php +++ b/src/Symfony/Component/Form/Extension/Core/Type/LocaleType.php @@ -15,7 +15,6 @@ use Symfony\Component\Form\ChoiceList\ArrayChoiceList; use Symfony\Component\Form\ChoiceList\Loader\ChoiceLoaderInterface; use Symfony\Component\Form\ChoiceList\Loader\IntlCallbackChoiceLoader; -use Symfony\Component\Form\Exception\LogicException; use Symfony\Component\Intl\Intl; use Symfony\Component\OptionsResolver\Options; use Symfony\Component\OptionsResolver\OptionsResolver; @@ -42,10 +41,6 @@ public function configureOptions(OptionsResolver $resolver) { $resolver->setDefaults(array( 'choice_loader' => function (Options $options) { - if (!class_exists(Intl::class)) { - throw new LogicException(sprintf('The "symfony/intl" component is required to use "%s".', static::class)); - } - $choiceTranslationLocale = $options['choice_translation_locale']; return new IntlCallbackChoiceLoader(function () use ($choiceTranslationLocale) { pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy