Bug #1332: Fix problem allowing to set empty values for userDn and password

FEA: ItEr76S04BugFixing
This commit is contained in:
Manuel Rego Casasnovas 2012-01-12 10:59:19 +01:00
parent c9356c71c7
commit deee4e8bd3

View file

@ -146,16 +146,6 @@ public class Configuration extends BaseEntity {
return true; return true;
} }
@AssertTrue(message = "userDn not specified")
public boolean checkConstraintLdapUserDnWithoutWhiteSpaces() {
if (getLdapConfiguration().getLdapAuthEnabled()) {
if (StringUtils.isBlank(getLdapConfiguration().getLdapUserDn())) {
return false;
}
}
return true;
}
@AssertTrue(message = "userId not specified") @AssertTrue(message = "userId not specified")
public boolean checkConstraintLdapUserIdWithoutWhiteSpaces() { public boolean checkConstraintLdapUserIdWithoutWhiteSpaces() {
if (getLdapConfiguration().getLdapAuthEnabled()) { if (getLdapConfiguration().getLdapAuthEnabled()) {
@ -166,16 +156,6 @@ public class Configuration extends BaseEntity {
return true; return true;
} }
@AssertTrue(message = "password not specified")
public boolean checkConstraintLdapPasswordWithoutWhiteSpaces() {
if (getLdapConfiguration().getLdapAuthEnabled()) {
if (StringUtils.isBlank(getLdapConfiguration().getLdapPassword())) {
return false;
}
}
return true;
}
public void setGenerateCodeForCriterion(Boolean generateCodeForCriterion) { public void setGenerateCodeForCriterion(Boolean generateCodeForCriterion) {
this.generateCodeForCriterion = generateCodeForCriterion; this.generateCodeForCriterion = generateCodeForCriterion;
} }