Skip to content

Commit 2c0ec1b

Browse files
committed
Polish
1 parent acfb07b commit 2c0ec1b

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

spring-boot/src/main/java/org/springframework/boot/context/properties/ConfigurationPropertiesBindingPostProcessor.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -322,15 +322,15 @@ private String getAnnotationDetails(ConfigurationProperties annotation) {
322322
}
323323

324324
private Validator determineValidator(Object bean) {
325-
boolean globalValidatorSupportBean = (this.validator != null
326-
&& this.validator.supports(bean.getClass()));
325+
boolean globalValidatorSupportBean = (this.validator != null && this.validator
326+
.supports(bean.getClass()));
327327
if (ClassUtils.isAssignable(Validator.class, bean.getClass())) {
328328
if (!globalValidatorSupportBean) {
329329
return (Validator) bean;
330330
}
331331
return new ChainingValidator(this.validator, (Validator) bean);
332332
}
333-
return globalValidatorSupportBean ? this.validator : null;
333+
return (globalValidatorSupportBean ? this.validator : null);
334334
}
335335

336336
private PropertySources loadPropertySources(String[] locations,

spring-boot/src/test/java/org/springframework/boot/context/properties/ConfigurationPropertiesBindingPostProcessorTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -429,7 +429,7 @@ public static class PropertyWithCustomValidator {
429429
private String foo;
430430

431431
public String getFoo() {
432-
return foo;
432+
return this.foo;
433433
}
434434

435435
public void setFoo(String foo) {

0 commit comments

Comments
 (0)