private function loadNodeConfig() { $loader = new YAMLParser($this->logger); $loader->setFilePath(__SITE_PATH . '/app/config/firewall.yml'); $config = $loader->loadConfig(); unset($loader); $parser = new URISectionComparator(); $key = $parser->findPattern($config, __URI); unset($parser); if (empty($key)) { return; } $this->node = $config[$key]; }
public function getFirewallKey(YAMLParser $parser) { $parser->setFilePath(__SITE_PATH . '/app/config/firewall.yml'); $config = $parser->loadConfig(); $comparator = new URISectionComparator(); $key = $comparator->findPattern($config, __URI); if ($key === false) { return null; } if (array_key_exists('authentication', $config[$key])) { return $config[$key]['authentication']; } return null; }