public static function getExceptionTrace(\Throwable $exception, $asString = true) {
        $trace = $exception->getTrace();
        $trace = static::reduceStackTrace($exception, $trace);
        return $asString ? static::getExceptionTraceAsString($trace) : $trace;
    }