N98\Magento\Application\ConfigurationLoader::registerPluginConfigFile PHP Method

registerPluginConfigFile() protected method

Loads a plugin config file and merges it to plugin config
protected registerPluginConfigFile ( string $magentoRootFolder, Symfony\Component\Finder\SplFileInfo $file )
$magentoRootFolder string
$file Symfony\Component\Finder\SplFileInfo
    protected function registerPluginConfigFile($magentoRootFolder, $file)
    {
        if (BinaryString::startsWith($file->getPathname(), 'vfs://')) {
            $path = $file->getPathname();
        } else {
            $path = $file->getRealPath();
            if ($path === "") {
                throw new \UnexpectedValueException(sprintf("Realpath for '%s' did return an empty string.", $file));
            }
            if ($path === false) {
                $this->log(sprintf("<error>Plugin config file broken link '%s'</error>", $file));
                return;
            }
        }
        $this->logDebug('Load plugin config <comment>' . $path . '</comment>');
        $localPluginConfigFile = ConfigFile::createFromFile($path);
        $localPluginConfigFile->applyVariables($magentoRootFolder, $file);
        $this->_pluginConfig = $localPluginConfigFile->mergeArray($this->_pluginConfig);
    }