From ae289cdb7d066d41c45d2b72cbc01572c94fe603 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Sun, 25 Sep 2022 22:36:04 +0200 Subject: [PATCH] Please cherry-pick: - branch offices have optional email addresses (finally found the bug that you always must enter an email address while the form field is not marked as required) MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../business/basicdata/AddressbookCompanyNameValidator.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/java/org/mxchange/addressbook/validator/business/basicdata/AddressbookCompanyNameValidator.java b/src/java/org/mxchange/addressbook/validator/business/basicdata/AddressbookCompanyNameValidator.java index f0ef3eb0..5bf52473 100644 --- a/src/java/org/mxchange/addressbook/validator/business/basicdata/AddressbookCompanyNameValidator.java +++ b/src/java/org/mxchange/addressbook/validator/business/basicdata/AddressbookCompanyNameValidator.java @@ -66,7 +66,7 @@ public class AddressbookCompanyNameValidator extends BaseStringValidator { final String[] requiredFields = {"companyName"}; //NOI18N // Pre-validation (example: not null, not a string, empty string ...) - super.preValidate(context, component, value, requiredFields, false); + super.preValidate(context, component, value, requiredFields, Boolean.FALSE); // Convert name to string (now securely checked in BaseStringValidator) final String companyName = (String) value; @@ -74,7 +74,7 @@ public class AddressbookCompanyNameValidator extends BaseStringValidator { // Default is to check on existing names Boolean checkExisting = Boolean.TRUE; - // Is attribute "allowEmptyValue" set? + // Is attribute "checkExisting" set? if (component.getAttributes().containsKey("checkExisting")) { //NOI18N // Get attribute final Object attribute = component.getAttributes().get("checkExisting"); //NOI18N -- 2.39.5