Skip to content

Commit c0aecaf

Browse files
committed
Delegate primitive type generation to swagger-core
1 parent 31a7cd3 commit c0aecaf

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

springdoc-openapi-common/src/main/java/org/springdoc/core/SpringDocAnnotationsUtils.java

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,7 @@ public class SpringDocAnnotationsUtils extends AnnotationsUtils {
4242

4343
public static Schema resolveSchemaFromType(Class<?> schemaImplementation, Components components,
4444
JsonView jsonView) {
45-
Schema schemaObject;
46-
PrimitiveType primitiveType = PrimitiveType.fromType(schemaImplementation);
47-
if (primitiveType != null) {
48-
schemaObject = primitiveType.createProperty();
49-
}
50-
else {
51-
schemaObject = extractSchema(components, schemaImplementation, jsonView);
52-
}
45+
Schema schemaObject = extractSchema(components, schemaImplementation, jsonView);
5346
if (schemaObject != null && StringUtils.isBlank(schemaObject.get$ref())
5447
&& StringUtils.isBlank(schemaObject.getType())) {
5548
// default to string

0 commit comments

Comments
 (0)