Skip to content

Commit 149ed09

Browse files
weixsunsnicoll
authored andcommitted
Polish SessionAutoConfiguration#addCandidateIfAvailable
See gh-27808
1 parent a7de44a commit 149ed09

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/session/SessionAutoConfiguration.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -239,10 +239,7 @@ private void checkAvailableImplementations() {
239239

240240
private void addCandidateIfAvailable(List<Class<?>> candidates, String type) {
241241
try {
242-
Class<?> candidate = Class.forName(type, false, this.classLoader);
243-
if (candidate != null) {
244-
candidates.add(candidate);
245-
}
242+
candidates.add(Class.forName(type, false, this.classLoader));
246243
}
247244
catch (Throwable ex) {
248245
// Ignore

0 commit comments

Comments
 (0)