diff --git a/core/modules/user/src/Plugin/migrate/process/d6/ProfileFieldOptionTranslation.php b/core/modules/user/src/Plugin/migrate/process/d6/ProfileFieldOptionTranslation.php index b16deee7b2..fb98743393 100644 --- a/core/modules/user/src/Plugin/migrate/process/d6/ProfileFieldOptionTranslation.php +++ b/core/modules/user/src/Plugin/migrate/process/d6/ProfileFieldOptionTranslation.php @@ -28,15 +28,10 @@ public function transform($value, MigrateExecutableInterface $migrate_executable $list = explode("\n", $translation); $list = array_map('trim', $list); $list = array_filter($list, 'strlen'); - switch ($field_type) { - case 'list_string': - case 'list_integer': - case 'list_float': - foreach ($list as $key => $value) { - $allowed_values[] = ['label' => $value]; - } - break; - + if ($field_type === 'list_string') { + foreach ($list as $key => $value) { + $allowed_values[] = ['label' => $value]; + } } $new_value = ['settings.allowed_values', $allowed_values]; } diff --git a/core/modules/user/src/Plugin/migrate/source/d6/ProfileFieldOptionTranslation.php b/core/modules/user/src/Plugin/migrate/source/d6/ProfileFieldOptionTranslation.php index d10cf5210e..b3eef04f53 100644 --- a/core/modules/user/src/Plugin/migrate/source/d6/ProfileFieldOptionTranslation.php +++ b/core/modules/user/src/Plugin/migrate/source/d6/ProfileFieldOptionTranslation.php @@ -47,10 +47,6 @@ public function fields() { /** * {@inheritdoc} */ - - /** - * {@inheritdoc} - */ public function getIds() { return parent::getIds() + [