Skip to content

Commit 7ee1347

Browse files
committed
Merge remote-tracking branch 'origin/main'
1 parent c2e1710 commit 7ee1347

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

springdoc-openapi-starter-common/src/main/java/org/springdoc/core/service/AbstractRequestService.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -666,7 +666,8 @@ public Parameter buildParam(ParameterInfo parameterInfo, Components components,
666666
jsonView);
667667
if (parameterInfo.getDefaultValue() != null && schema != null) {
668668
Object defaultValue = SpringDocAnnotationsUtils.castDefaultValue(schema, parameterInfo.getDefaultValue());
669-
schema.setDefault(defaultValue);
669+
if (defaultValue != null)
670+
schema.setDefault(defaultValue);
670671
}
671672
parameter.setSchema(schema);
672673
}

0 commit comments

Comments
 (0)