Merge pull request #16388 from eugenp/fix-autowired

Remove Autowired annotation
This commit is contained in:
Ulisses Lima 2024-04-13 01:38:10 -03:00 committed by GitHub
commit 38bb8c3e91
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 0 additions and 2 deletions

View File

@ -1,6 +1,5 @@
package com.baeldung.filter;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.web.servlet.FilterRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@ -18,7 +17,6 @@ public class AppConfig {
}
@Bean
@Autowired
public FilterRegistrationBean<LoggingFilterRegistrationBean> loggingFilterRegistration(LoggingService loggingService) {
FilterRegistrationBean<LoggingFilterRegistrationBean> registrationBean = new FilterRegistrationBean<>();
registrationBean.setFilter(new LoggingFilterRegistrationBean(loggingService));