public function displayError($ex)
 {
     try {
         $errorModel = ['code' => $ex->getCode(), 'message' => $ex->getMessage()];
         return new View('Errors', 'Error', $errorModel);
     } catch (\Exception $exc) {
         \RedDevil\Core\Common::headerStatus($ex->getCode());
         echo '<h1>' . $ex . '</h1>';
         exit;
     }
 }
 public function session(string $name, bool $normalize = null, $default = null)
 {
     if ($this->hasSession($name)) {
         if ($normalize != null) {
             return Common::normalize($this->_session[$name], $normalize);
         }
         return $this->_session[$name];
     }
     return $default;
 }