Browse Source

Revert "Polish"

This reverts commit 0f612596c7.
pull/46604/head
Phillip Webb 5 months ago
parent
commit
a8172e2601
  1. 6
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/util/LambdaSafe.java

6
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/util/LambdaSafe.java

@ -349,8 +349,10 @@ public final class LambdaSafe { @@ -349,8 +349,10 @@ public final class LambdaSafe {
@Override
public boolean match(Class<C> callbackType, C callbackInstance, A argument, Object[] additionalArguments) {
ResolvableType type = ResolvableType.forClass(callbackType, callbackInstance.getClass());
return type.getGenerics().length == 1 && type.resolveGeneric() != null
&& type.resolveGeneric().isInstance(argument);
if (type.getGenerics().length == 1 && type.resolveGeneric() != null) {
return type.resolveGeneric().isInstance(argument);
}
return true;
}
}

Loading…
Cancel
Save