Closed
Description
In ModelUtils
those two methods return a single Schema
for a RequestBody
or a ApiResponse
:
ModelUtils.getSchemaFromRequestBody(RequestBody)
ModelUtils.getSchemaFromResponse(ApiResponse)
This feels wrong because when multiple Mime types are defined (like application/json
or application/xml
) different Schemas can be returned.
With #74 an additional warning log was added:
[main] WARN org.openapitools.codegen.utils.ModelUtils - Multiple schemas found, returning only the first one
We should investigate on the impacts.
When multiple mime types are defined we might need to compare if the defined schema are different or not.