src/Handler/Error.php
protected function render(\Throwable $error):Message
    {
        $message = new Message();
        $e = $message->add(static::TITLE, $error->getMessage())
            ->setStatus(static::HTTP_STATUS)
            ->setCode($error->getCode());

        if ($this->displayErrorDetails) {
            $e->setSource(
                [
                    'file' => $error->getFile(),
                    'line' => $error->getLine()
                ]
            )->setMeta(
                [
                    'trace' => explode("\n", $error->getTraceAsString())
                ]
            );
        }

        return $message;
    }
protected function render(\Throwable $error):Message
    {
        $message = new Message();
        $e = $message->add(static::TITLE, $error->getMessage())
            ->setStatus(static::HTTP_STATUS)
            ->setCode($error->getCode());

        if ($this->displayErrorDetails) {
            $e->setSource(
                [
                    'file' => $error->getFile(),
                    'line' => $error->getLine()
                ]
            )->setMeta(
                [
                    'trace' => explode("\n", $error->getTraceAsString())
                ]
            );
        }

        return $message;
    }
protected function render ( \ Throwable $ error ) : Message { $ message = new Message ( ) ; $ e = $ message -> add ( static :: TITLE , $ error -> getMessage ( ) ) -> setStatus ( static :: HTTP_STATUS ) -> setCode ( $ error -> getCode ( ) ) ; if ( $ this -> displayErrorDetails ) { $ e -> setSource ( [ 'file' => $ error -> getFile ( ) , 'line' => $ error -> getLine ( ) ] ) -> setMeta ( [ 'trace' => explode ( "\n" , $ error -> getTraceAsString ( ) ) ] ) ; } return $ message ; }
Renderiza el mensaje de error

@param \Throwable $error Instancia de Throwable

@return Message
Renderiza el mensaje de error