diff --git a/core/modules/field/config/field.settings.yml b/core/modules/field/config/field.settings.yml index df6f2a9..51cf519 100644 --- a/core/modules/field/config/field.settings.yml +++ b/core/modules/field/config/field.settings.yml @@ -1,2 +1,2 @@ purge_batch_size: 10 -storage_default: 'field_sql_storage' +storage_default: field_sql_storage diff --git a/core/modules/field/field.api.php b/core/modules/field/field.api.php index 4fdc075..3404ce8 100644 --- a/core/modules/field/field.api.php +++ b/core/modules/field/field.api.php @@ -1133,7 +1133,7 @@ function hook_field_attach_prepare_translation_alter(\Drupal\Core\Entity\EntityI function hook_field_language_alter(&$display_langcode, $context) { // Do not apply core language fallback rules if they are disabled or if Locale // is not registered as a translation handler. - if (state('field')->get('language_fallback') && field_has_translation_handler($context['entity']->entityType())) { + if (state()->get('field.language_fallback') && field_has_translation_handler($context['entity']->entityType())) { field_language_fallback($display_langcode, $context['entity'], $context['langcode']); } } diff --git a/core/modules/field/field.multilingual.inc b/core/modules/field/field.multilingual.inc index 532cae3..0943849 100644 --- a/core/modules/field/field.multilingual.inc +++ b/core/modules/field/field.multilingual.inc @@ -81,7 +81,7 @@ function field_language_insert() { // Because the language_count is updated only after the hook is invoked, we // check if the language_count is bigger or equal with 1 at the current time. if (variable_get('language_count', 1) >= 1) { - state('field')->set('language_fallback', TRUE)->save(); + state()->set('field.language_fallback', TRUE); } } @@ -102,7 +102,7 @@ function field_language_delete() { // Because the language_count is updated after the hook is invoked, we check // if the language_count is less or equal with 2 at the current time. if (variable_get('language_count', 1) <= 2) { - state('field')->set('language_fallback', FALSE)->save(); + state()->set('field.language_fallback', FALSE); } } @@ -336,7 +336,7 @@ function field_language(EntityInterface $entity, $field_name = NULL, $langcode = ); // Do not apply core language fallback rules if they are disabled or if // the entity does not have a translation handler registered. - if (state('field')->get('language_fallback') && field_has_translation_handler($entity_type)) { + if (state()->get('field.language_fallback') && field_has_translation_handler($entity_type)) { field_language_fallback($display_langcode, $context['entity'], $context['langcode']); } drupal_alter('field_language', $display_langcode, $context); diff --git a/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php b/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php index 0718a52..ffb1292 100644 --- a/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php +++ b/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php @@ -196,7 +196,7 @@ public function query($use_groupby = FALSE) { $this->view->display_handler->options['field_langcode']); $placeholder = $this->placeholder(); $langcode_fallback_candidates = array($langcode); - if (state('field')->get('language_fallback')) { + if (state()->get('field.language_fallback')) { require_once DRUPAL_ROOT . '/includes/language.inc'; $langcode_fallback_candidates = array_merge($langcode_fallback_candidates, language_fallback_get_candidates()); } diff --git a/core/modules/field/lib/Drupal/field/Tests/FieldUnitTestBase.php b/core/modules/field/lib/Drupal/field/Tests/FieldUnitTestBase.php index de3c3d6..ec47261 100644 --- a/core/modules/field/lib/Drupal/field/Tests/FieldUnitTestBase.php +++ b/core/modules/field/lib/Drupal/field/Tests/FieldUnitTestBase.php @@ -41,7 +41,7 @@ function setUp() { $this->installSchema('field_test', array('test_entity', 'test_entity_revision', 'test_entity_bundle')); // Set default storage backend. - config('field.setttings')->set('storage_default', $this->default_storage)->save(); + config('field.settings')->set('storage_default', $this->default_storage)->save(); } /**