Skip to content

Commit e731746

Browse files
committed
Fix exception message about producible media types
Issue: SPR-10175
1 parent f2d7d66 commit e731746

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/mvc/method/annotation/AbstractMessageConverterMethodProcessor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ protected <T> void writeWithMessageConverters(T returnValue,
112112
}
113113
}
114114
if (compatibleMediaTypes.isEmpty()) {
115-
throw new HttpMediaTypeNotAcceptableException(allSupportedMediaTypes);
115+
throw new HttpMediaTypeNotAcceptableException(producibleMediaTypes);
116116
}
117117

118118
List<MediaType> mediaTypes = new ArrayList<MediaType>(compatibleMediaTypes);

0 commit comments

Comments
 (0)