/**
  * Serves error view
  * 
  * @return void
  */
 protected function serveView()
 {
     if ($this->devEnv) {
         $view = $this->e->getMessage();
     } else {
         $code = $this->e->getCode();
         if ($code) {
             $this->io->httpCode($code);
             $parameters = ['code' => $code];
         } else {
             $parameters = null;
         }
         $view = $this->fileSystem->containeredInclude($this->errorView, $parameters);
     }
     $this->io->toEcho($view);
 }
Exemple #2
0
 /**
  * {@inheritdoc}
  * @see \rakelley\jhframe\classes\View::constructView()
  */
 public function constructView()
 {
     $this->viewContent = $this->fileSystem->containeredInclude($this->file);
 }