示例#1
0
 private function runError(\Exception $e)
 {
     try {
         $request = new Request();
         $request->setProperty('app_error', $e);
         $request->setProperty('controller', 'error');
         $request->setProperty('action', 'index');
         RequestRegistry::setRequest($request);
         $cmdResolver = new CommandResolver();
         $cmd = $cmdResolver->getCmd($request);
         $cmd->execute();
     } catch (\Exception $e) {
         echo $e->getMessage();
         exit;
     }
 }
示例#2
0
 public function __construct()
 {
     $this->init();
     RequestRegistry::setRequest($this);
 }