Piwik\API\ResponseBuilder::formatExceptionMessage PHP Method

formatExceptionMessage() private method

private formatExceptionMessage ( Exceptio\Exception | Throwable $exception ) : string
$exception Exceptio\Exception | Throwable
return string
    private function formatExceptionMessage($exception)
    {
        $message = $exception->getMessage();
        if (\Piwik_ShouldPrintBackTraceWithMessage()) {
            $message .= "\n" . $exception->getTraceAsString();
        }
        return Renderer::formatValueXml($message);
    }