diff --git a/core/lib/Drupal/Core/Config/ConfigFactory.php b/core/lib/Drupal/Core/Config/ConfigFactory.php index 2cde0d4..20a53e7 100644 --- a/core/lib/Drupal/Core/Config/ConfigFactory.php +++ b/core/lib/Drupal/Core/Config/ConfigFactory.php @@ -104,7 +104,7 @@ public function getOverrideState() { /** * {@inheritdoc} */ - public function getEditable($name, $override_free = TRUE) { + public function getEditable($name) { $old_state = $this->getOverrideState(); $this->setOverrideState(FALSE); $config = $this->doGet($name, FALSE); diff --git a/core/lib/Drupal/Core/Menu/StaticMenuLinkOverrides.php b/core/lib/Drupal/Core/Menu/StaticMenuLinkOverrides.php index c070e12..cbc485c 100644 --- a/core/lib/Drupal/Core/Menu/StaticMenuLinkOverrides.php +++ b/core/lib/Drupal/Core/Menu/StaticMenuLinkOverrides.php @@ -140,7 +140,7 @@ public function saveOverride($id, array $definition) { $definition = array_intersect_key($definition, $expected); if ($definition) { $id = static::encodeId($id); - $all_overrides = $this->getConfig()->get('definitions', FALSE); + $all_overrides = $this->getConfig()->get('definitions'); // Combine with any existing data. $all_overrides[$id] = $definition + $this->loadOverride($id); $this->getConfig()->set('definitions', $all_overrides)->save(); diff --git a/core/modules/color/color.module b/core/modules/color/color.module index 7d8473c..8bbb035 100644 --- a/core/modules/color/color.module +++ b/core/modules/color/color.module @@ -169,8 +169,9 @@ function color_get_palette($theme, $default = FALSE) { // Load variable. // @todo Default color config should be moved to yaml in the theme. - // Getting a mutable override-free object because overriding color - // configuration makes no sense. + // Getting a mutable override-free object because this function is only used + // in forms. Color configuration is used to write CSS to the file system + // making configuration overrides pointless. return \Drupal::configFactory()->getEditable('color.theme.' . $theme)->get('palette') ?: $palette; } @@ -200,9 +201,8 @@ function color_scheme_form($complete_form, FormStateInterface $form_state, $them // Note: we use the original theme when the default scheme is chosen. // Note: we use configuration without overrides since this information is used // in a form and therefore without doing this would bleed overrides into - // active configuration. - // Getting a mutable override-free object because overriding color - // configuration makes no sense. + // active configuration. Furthermore, color configuration is used to write + // CSS to the file system making configuration overrides pointless. $current_scheme = \Drupal::configFactory()->getEditable('color.theme.' . $theme)->get('palette'); foreach ($schemes as $key => $scheme) { if ($current_scheme == $scheme) { diff --git a/core/modules/locale/locale.module b/core/modules/locale/locale.module index 79b2a50..52a5eb9 100644 --- a/core/modules/locale/locale.module +++ b/core/modules/locale/locale.module @@ -665,8 +665,6 @@ function locale_form_language_admin_edit_form_alter_submit($form, FormStateInter * * @return bool * Returns TRUE if content should be translated to English, FALSE otherwise. - * - * @fixme remove this method */ function locale_translate_english() { return \Drupal::config('locale.settings')->get('translate_english'); diff --git a/core/modules/simpletest/src/KernelTestBase.php b/core/modules/simpletest/src/KernelTestBase.php index f21ffb3..de21ce4 100644 --- a/core/modules/simpletest/src/KernelTestBase.php +++ b/core/modules/simpletest/src/KernelTestBase.php @@ -203,9 +203,9 @@ protected function setUp() { $this->enableModules($modules); } // In order to use theme functions default theme config needs to exist. This - // configuration is not actually saved because it does not need to be. If it - // was saved then all KernelTestBase tests would need to install the system - // module of the schema would be missing. + // configuration is not saved because it would fatal due to system module's + // configuration schema not existing. However since the configuration is + // cached in the configuration factory everything works. $this->config('system.theme')->set('default', 'classy'); // Tests based on this class are entitled to use Drupal's File and