Browse Source

Fix typo in ExceptionMapingComparator name

Closes gh-36422

Signed-off-by: 신성현 <froggy0m0a@gmail.com>
pull/36429/head
froggy0m0 2 weeks ago committed by GitHub
parent
commit
de417beff7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 6
      spring-web/src/main/java/org/springframework/web/method/annotation/ExceptionHandlerMethodResolver.java

6
spring-web/src/main/java/org/springframework/web/method/annotation/ExceptionHandlerMethodResolver.java

@ -236,7 +236,7 @@ public class ExceptionHandlerMethodResolver { @@ -236,7 +236,7 @@ public class ExceptionHandlerMethodResolver {
}
if (!matches.isEmpty()) {
if (matches.size() > 1) {
matches.sort(new ExceptionMapingComparator(exceptionType, mediaType));
matches.sort(new ExceptionMappingComparator(exceptionType, mediaType));
}
return Objects.requireNonNull(this.mappedMethods.get(matches.get(0)));
}
@ -263,13 +263,13 @@ public class ExceptionHandlerMethodResolver { @@ -263,13 +263,13 @@ public class ExceptionHandlerMethodResolver {
}
}
private static class ExceptionMapingComparator implements Comparator<ExceptionMapping> {
private static class ExceptionMappingComparator implements Comparator<ExceptionMapping> {
private final ExceptionDepthComparator exceptionDepthComparator;
private final MediaType mediaType;
public ExceptionMapingComparator(Class<? extends Throwable> exceptionType, MediaType mediaType) {
public ExceptionMappingComparator(Class<? extends Throwable> exceptionType, MediaType mediaType) {
this.exceptionDepthComparator = new ExceptionDepthComparator(exceptionType);
this.mediaType = mediaType;
}

Loading…
Cancel
Save