예제 #1
0
 protected function errorHandler(BaseException $e)
 {
     $this->statusCode($e->getCode());
     $this->view->message = $e->getMessage();
     $this->view->code = $e->getCode();
     $this->view->contextMessage = $e->getContextMessage();
     $this->view->display('error');
 }
예제 #2
0
 public function handle(BaseException $e)
 {
     if ($e->level === 2) {
         if (!IS_DEBUG) {
             $this->runErrorAction(new E500Exception($e->getMessage()));
         } else {
             $this->showException($e);
         }
     } else {
         $this->runErrorAction($e);
     }
 }
 /**
  * Constructor
  * 
  * @param array $errors
  * @param string $error
  */
 public function __construct($error = 'Entry not found.', $errors = [])
 {
     parent::__construct($error, $errors);
 }
 /**
  * Constructor
  * 
  * @param array $errors
  * @param string $error
  */
 public function __construct($error = 'Validation errors.', $errors = [])
 {
     parent::__construct($error, $errors);
 }
 /**
  * Constructor
  * 
  * @param array $errors
  * @param string $error
  */
 public function __construct($error = 'Could not save entry.', $errors = [])
 {
     parent::__construct($error, $errors);
 }