Example #1
0
File: App.php Project: finef/app
 public function onHttpkernelResolveController(Event $event)
 {
     $module = $event->getRouteResult()->getParam('module');
     $controller = $event->getRouteResult()->getParam('controller');
     $controllers = $event->fine->mod->app->controller;
     if (!isset($controllers->{$module}) || !isset($controllers->{$module}->{$controller})) {
         throw new Http404NotFoundException();
     }
     $event->setController($controllers->{$module}->{$controller});
 }