From 60228453f0f6f6278207f27a2fc09cdbfcd9c4c0 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/PizzaCompanyNameValidator.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/java/org/mxchange/pizzaapplication/validator/business/basicdata/PizzaCompanyNameValidator.java b/src/java/org/mxchange/pizzaapplication/validator/business/basicdata/PizzaCompanyNameValidator.java index 33bef796..d45804e0 100644 --- a/src/java/org/mxchange/pizzaapplication/validator/business/basicdata/PizzaCompanyNameValidator.java +++ b/src/java/org/mxchange/pizzaapplication/validator/business/basicdata/PizzaCompanyNameValidator.java @@ -66,7 +66,7 @@ public class PizzaCompanyNameValidator 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 PizzaCompanyNameValidator 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