php-mezzio-ph-modern.InternalServerError.php.mustache Maven / Gradle / Ivy
handle($request);
ErrorHandler::stop(true);
}
catch (\Throwable $error) {
$result = $this->handleError($error);
}
return $result;
}
public function handleError(\Throwable $error): ResponseInterface
{
\error_log((string)$error);
return $this->generateEmptyResponse()->withStatus(500, 'Internal server error');
}
protected function generateEmptyResponse(): ResponseInterface
{
return ($this->responseGenerator)();
}
}