grthtrhthjhtyjytjytkergtrhtrjytjerhrfh4:24 29/09/2026withStatus($status) ->withHeader('Accept', static::MEDIA_TYPE) ->withHeader('Content-type', static::MEDIA_TYPE) ->write( json_encode( $response, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES ) ); } /** * @param HttpResponse $httpResponse * @param \Exception $exception * @param integer $status * * @return HttpResponse */ public function generateErrorResponse(HttpResponse $httpResponse, \Exception $exception, $status) { $response = new ErrorResponse(); $response->setStatus($status); $response->setDetail($exception->getMessage()); $response->setException($exception); return $this->generateResponse($httpResponse, $response, $status); } }