public function find_routing_files(array $paths)
{
$this->routing_files = array('config/' . $this->environment . '/routing/environment.yml');
foreach ($paths as $path) {
if (file_exists($this->phpbb_root_path . $path . 'config/' . $this->environment . '/routing/environment.yml')) {
$this->routing_files[] = $path . 'config/' . $this->environment . '/routing/environment.yml';
} else {
if (!is_dir($this->phpbb_root_path . $path . 'config/' . $this->environment)) {
if (file_exists($this->phpbb_root_path . $path . 'config/default/routing/environment.yml')) {
$this->routing_files[] = $path . 'config/default/routing/environment.yml';
} else {
if (!is_dir($this->phpbb_root_path . $path . 'config/default/routing') && file_exists($this->phpbb_root_path . $path . 'config/routing.yml')) {
$this->routing_files[] = $path . 'config/routing.yml';
}
}
}
}
}
return $this;
}