Skip to content

Commit afaf8ca

Browse files
committed
Polish remove unused code
Signed-off-by: DingHao <[email protected]>
1 parent fe9edc8 commit afaf8ca

File tree

1 file changed

+2
-13
lines changed

1 file changed

+2
-13
lines changed

config/src/main/java/org/springframework/security/config/annotation/web/configuration/WebSecurityConfiguration.java

+2-13
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2022 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -22,7 +22,6 @@
2222

2323
import jakarta.servlet.Filter;
2424

25-
import org.springframework.beans.factory.BeanClassLoaderAware;
2625
import org.springframework.beans.factory.annotation.Autowired;
2726
import org.springframework.beans.factory.config.BeanFactoryPostProcessor;
2827
import org.springframework.beans.factory.config.ConfigurableListableBeanFactory;
@@ -65,20 +64,16 @@
6564
* @see WebSecurity
6665
*/
6766
@Configuration(proxyBeanMethods = false)
68-
public class WebSecurityConfiguration implements ImportAware, BeanClassLoaderAware {
67+
public class WebSecurityConfiguration implements ImportAware {
6968

7069
private WebSecurity webSecurity;
7170

7271
private Boolean debugEnabled;
7372

74-
private List<SecurityConfigurer<Filter, WebSecurity>> webSecurityConfigurers;
75-
7673
private List<SecurityFilterChain> securityFilterChains = Collections.emptyList();
7774

7875
private List<WebSecurityCustomizer> webSecurityCustomizers = Collections.emptyList();
7976

80-
private ClassLoader beanClassLoader;
81-
8277
@Autowired(required = false)
8378
private HttpSecurity httpSecurity;
8479

@@ -164,7 +159,6 @@ public void setFilterChainProxySecurityConfigurer(ObjectPostProcessor<Object> ob
164159
for (SecurityConfigurer<Filter, WebSecurity> webSecurityConfigurer : webSecurityConfigurers) {
165160
this.webSecurity.apply(webSecurityConfigurer);
166161
}
167-
this.webSecurityConfigurers = webSecurityConfigurers;
168162
}
169163

170164
@Autowired(required = false)
@@ -193,11 +187,6 @@ public void setImportMetadata(AnnotationMetadata importMetadata) {
193187
}
194188
}
195189

196-
@Override
197-
public void setBeanClassLoader(ClassLoader classLoader) {
198-
this.beanClassLoader = classLoader;
199-
}
200-
201190
/**
202191
* A custom version of the Spring provided AnnotationAwareOrderComparator that uses
203192
* {@link AnnotationUtils#findAnnotation(Class, Class)} to look on super class

0 commit comments

Comments
 (0)