protected function Requirements::loadConfig in MongoDB 8.2
Load the configuration from default or from active configuration.
Parameters
bool $useDefault: Use default configuration ?
1 call to Requirements::loadConfig()
- Requirements::check in modules/
mongodb_watchdog/ src/ Install/ Requirements.php - Implements hook_requirements().
File
- modules/
mongodb_watchdog/ src/ Install/ Requirements.php, line 158
Class
- Requirements
- Class Requirements implements hook_requirements().
Namespace
Drupal\mongodb_watchdog\InstallCode
protected function loadConfig(bool $useDefault) : void {
if ($useDefault) {
$rawDefaultConfig = file_get_contents(__DIR__ . '/../../config/install/mongodb_watchdog.settings.yml');
$defaultConfigData = $this->serialization
->decode($rawDefaultConfig);
$this->config = $this->configFactory
->getEditable(Logger::MODULE);
$this->config
->initWithData($defaultConfigData);
return;
}
$this->config = $this->configFactory
->get(Logger::CONFIG_NAME);
}