Bolt\Extension\ConfigTrait::addConfig PHP Method

addConfig() private method

Merge in a yaml file to the config.
private addConfig ( Bolt\Filesystem\Handler\YamlFile $file )
$file Bolt\Filesystem\Handler\YamlFile
    private function addConfig(YamlFile $file)
    {
        $app = $this->getContainer();
        try {
            $newConfig = $file->parse();
        } catch (RuntimeException $e) {
            $app['logger.flash']->danger($e->getMessage());
            $app['logger.system']->error($e->getMessage(), ['event' => 'exception', 'exception' => $e]);
            throw $e;
        }
        if (is_array($newConfig)) {
            $this->config = Arr::replaceRecursive($this->config, $newConfig);
        }
    }