Created
April 7, 2018 10:15
-
-
Save andy221166/806ea2c9205c3630c87b6172dcd1fa29 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* This configuration helps support for load javax/hibernate validator message by custom key | |
* | |
* @return | |
*/ | |
@Bean | |
public Validator validator() { | |
final LocalValidatorFactoryBean factory = new LocalValidatorFactoryBean(); | |
factory.setValidationMessageSource(messageSource()); | |
return factory; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment