Skip to content
Snippets Groups Projects
Verified Commit d2c67dda authored by Sven Kirschbaum's avatar Sven Kirschbaum
Browse files

:goal: Hide Error Details for non STACK Exceptions

parent 7152f9e9
No related branches found
No related tags found
No related merge requests found
......@@ -8,8 +8,9 @@ class ErrorRenderer implements ErrorRendererInterface
{
public function __invoke(\Throwable $exception, bool $displayErrorDetails): string
{
$message = $exception instanceof \stack_exception ? $exception->getMessage() : "An Error occured while processing the question";
return json_encode(array(
'message' => $exception->getMessage()
'message' => $message
));
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment