Skip to content

Commit d979296

Browse files
authored
correcting JsonSerialize as check
as is not required and returns Void by default.
1 parent caa5eda commit d979296

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/swagger-core/src/main/java/io/swagger/jackson/ModelResolver.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@ public Model resolve(JavaType type, ModelConverterContext context, Iterator<Mode
311311
//If JsonSerialize(as=...) is specified then use that bean to figure out all the json-like bits
312312
JsonSerialize jasonSerialize = beanDesc.getClassAnnotations().get(JsonSerialize.class);
313313
if (jasonSerialize != null) {
314-
if (jasonSerialize.as() != null) {
314+
if (jasonSerialize.as() != Void.class) {
315315
JavaType asType = _mapper.constructType(jasonSerialize.as());
316316
beanDesc = _mapper.getSerializationConfig().introspect(asType);
317317
}

0 commit comments

Comments
 (0)