forked from loafle/openapi-generator-original
Fix returnBaseType in Map response (#6246)
* fix returnBaseType for map response * fix javadoc string
This commit is contained in:
parent
646c2bc23c
commit
18c57a65ed
@ -2181,6 +2181,10 @@ public class DefaultCodegen {
|
||||
ArrayProperty ap = (ArrayProperty) responseProperty;
|
||||
CodegenProperty innerProperty = fromProperty("response", ap.getItems());
|
||||
op.returnBaseType = innerProperty.baseType;
|
||||
} else if (responseProperty instanceof MapProperty) {
|
||||
MapProperty ap = (MapProperty) responseProperty;
|
||||
CodegenProperty innerProperty = fromProperty("response", ap.getAdditionalProperties());
|
||||
op.returnBaseType = innerProperty.baseType;
|
||||
} else {
|
||||
if (cm.complexType != null) {
|
||||
op.returnBaseType = cm.complexType;
|
||||
@ -3658,7 +3662,7 @@ public class DefaultCodegen {
|
||||
* writes it back to additionalProperties to be usable as a boolean in
|
||||
* mustache files.
|
||||
*
|
||||
* @param propertyKey
|
||||
* @param propertyKey property key
|
||||
* @return property value as boolean
|
||||
*/
|
||||
public boolean convertPropertyToBooleanAndWriteBack(String propertyKey) {
|
||||
|
@ -400,8 +400,8 @@ public class InlineModelResolver {
|
||||
/**
|
||||
* Make a RefProperty
|
||||
*
|
||||
* @param ref
|
||||
* @param property
|
||||
* @param ref new property name
|
||||
* @param property Property
|
||||
* @return
|
||||
*/
|
||||
public Property makeRefProperty(String ref, Property property) {
|
||||
@ -413,8 +413,8 @@ public class InlineModelResolver {
|
||||
/**
|
||||
* Copy vendor extensions from Property to another Property
|
||||
*
|
||||
* @param source
|
||||
* @param target
|
||||
* @param source soruce property
|
||||
* @param target target property
|
||||
*/
|
||||
public void copyVendorExtensions(Property source, AbstractProperty target) {
|
||||
Map<String, Object> vendorExtensions = source.getVendorExtensions();
|
||||
|
Loading…
x
Reference in New Issue
Block a user