loadOverrides example

protected function doGet($name$immutable = TRUE) {
    if ($config = $this->doLoadMultiple([$name]$immutable)) {
      return $config[$name];
    }
    else {
      // If the configuration object does not exist in the configuration       // storage, create a new object.       $config = $this->createConfigObject($name$immutable);

      if ($immutable) {
        // Get and apply any overrides.         $overrides = $this->loadOverrides([$name]);
        if (isset($overrides[$name])) {
          $config->setModuleOverride($overrides[$name]);
        }
        // Apply any settings.php overrides.         if (isset($GLOBALS['config'][$name])) {
          $config->setSettingsOverride($GLOBALS['config'][$name]);
        }
      }

      foreach ($this->configFactoryOverrides as $override) {
        $config->addCacheableDependency($override->getCacheableMetadata($name));
      }
Home | Imprint | This part of the site doesn't use cookies.