fix param validation
This commit is contained in:
@@ -5,8 +5,10 @@ import java.util.ResourceBundle;
|
||||
|
||||
import org.springframework.context.MessageSource;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.ComponentScan;
|
||||
import org.springframework.context.support.MessageSourceResourceBundle;
|
||||
import org.springframework.context.support.ResourceBundleMessageSource;
|
||||
import org.springframework.validation.beanvalidation.MethodValidationPostProcessor;
|
||||
import org.springframework.web.servlet.ViewResolver;
|
||||
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
|
||||
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
|
||||
@@ -15,6 +17,7 @@ import org.springframework.web.servlet.view.JstlView;
|
||||
|
||||
//@EnableWebMvc
|
||||
//@Configuration
|
||||
@ComponentScan("com.baeldung.spring")
|
||||
public class ClientWebConfigJava implements WebMvcConfigurer {
|
||||
|
||||
public ClientWebConfigJava() {
|
||||
@@ -51,4 +54,9 @@ public class ClientWebConfigJava implements WebMvcConfigurer {
|
||||
|
||||
return bean;
|
||||
}
|
||||
|
||||
@Bean
|
||||
public MethodValidationPostProcessor methodValidationPostProcessor() {
|
||||
return new MethodValidationPostProcessor();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user