/** * execute * * @param mixed $filterChain * @access public * @return void */ public function execute($filterChain) { if ($this->isFirstCall()) { if (file_exists(sfConfig::get('sf_config_dir') . '/navigation.yml')) { $path = sfConfig::get('sf_config_dir') . '/navigation.yml'; } else { $path = sfConfig::get('sf_app_config_dir') . '/navigation.yml'; } include sfContext::getInstance()->getConfigCache()->checkConfig($path); csNavigationHelper::init($settings, $navigation); } $filterChain->execute(); }
protected function execute($arguments = array(), $options = array()) { $app = $arguments['application']; $env = $options['env']; $this->checkAppExists($app); $this->bootstrapSymfony($app, $env, true); $context = sfContext::getInstance(); // Remove existing cache files $this->runSymfonyCacheClear(); $this->logSection('navigation', 'loading navigation.yml'); /* TODO What happens when the user has two or more applications with separate navigation.yml files? We may want to restructure (migrate) the tree rather than drop it and rebuild it! */ if (file_exists(sfConfig::get('sf_config_dir') . '/navigation.yml')) { $path = sfConfig::get('sf_config_dir') . '/navigation.yml'; } else { $path = sfConfig::get('sf_app_config_dir') . '/navigation.yml'; } include sfContext::getInstance()->getConfiguration()->getConfigCache()->checkConfig($path); csNavigationHelper::init($settings, $navigation, true); $this->logSection('navigation', "Completed."); }