Update kotlin-client okHttp3 api.mustache fixes 16410 (#16411)

- populate body into the ServerException message
This commit is contained in:
Robert Oschwald
2023-08-25 20:06:43 +02:00
committed by GitHub
parent 0f8f18e727
commit ec835fbd94
47 changed files with 251 additions and 251 deletions

View File

@@ -69,7 +69,7 @@ class DefaultApi(basePath: kotlin.String = defaultBasePath, client: OkHttpClient
}
ResponseType.ServerError -> {
val localVarError = localVarResponse as ServerError<*>
throw ServerException("Server error : ${localVarError.statusCode} ${localVarError.message.orEmpty()}", localVarError.statusCode, localVarResponse)
throw ServerException("Server error : ${localVarError.statusCode} ${localVarError.message.orEmpty()} ${localVarError.body}", localVarError.statusCode, localVarResponse)
}
}
}