diff --git a/src/bundle/Resources/public/js/scripts/helpers/form.validation.helper.js b/src/bundle/Resources/public/js/scripts/helpers/form.validation.helper.js index 8955eded8f..39dea36a46 100644 --- a/src/bundle/Resources/public/js/scripts/helpers/form.validation.helper.js +++ b/src/bundle/Resources/public/js/scripts/helpers/form.validation.helper.js @@ -29,7 +29,7 @@ const checkIsEmpty = (field) => { } return { - isValid: input?.value ?? true, + isValid: (input.value || input.value === 0) ?? false, errorMessage, }; }; @@ -57,4 +57,4 @@ const validateIsEmptyField = (field) => { return validatorOutput; }; -export { formatErrorLine, validateIsEmptyField }; +export { formatErrorLine, validateIsEmptyField, checkIsEmpty };