minor #29720 Revert "minor #28610 [Form] Check for Intl availibility (ro0NL)" (chalasr)

This PR was merged into the 4.2 branch.

Discussion
----------

Revert "minor #28610 [Form] Check for Intl availibility (ro0NL)"

| Q             | A
| ------------- | ---
| Branch?       | 4.2
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Intl is an hard dependency for Form, these checks cannot be reached.

Commits
-------

3ac98a6a17 Revert "minor #28610 [Form] Check for Intl availibility (ro0NL)"
This commit is contained in:
Nicolas Grekas 2019-01-03 16:00:40 +01:00
commit 4f567326d0
4 changed files with 0 additions and 20 deletions

View File

@ -15,7 +15,6 @@ use Symfony\Component\Form\AbstractType;
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 @@ class CountryType extends AbstractType implements ChoiceLoaderInterface
{
$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) {

View File

@ -15,7 +15,6 @@ use Symfony\Component\Form\AbstractType;
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 @@ class CurrencyType extends AbstractType implements ChoiceLoaderInterface
{
$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) {

View File

@ -15,7 +15,6 @@ use Symfony\Component\Form\AbstractType;
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 @@ class LanguageType extends AbstractType implements ChoiceLoaderInterface
{
$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) {

View File

@ -15,7 +15,6 @@ use Symfony\Component\Form\AbstractType;
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 @@ class LocaleType extends AbstractType implements ChoiceLoaderInterface
{
$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) {