From f07b12ebd40fff36a0e0884c7d473ae6ea8c4fa5 Mon Sep 17 00:00:00 2001 From: darinda Date: Thu, 13 Jul 2017 11:05:26 +0200 Subject: [PATCH] Fix error for integer field type integer field type returns 'null' for not specified min or max values rather than 'false' --- Form/FieldTypeHandler/IntegerHandler.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Form/FieldTypeHandler/IntegerHandler.php b/Form/FieldTypeHandler/IntegerHandler.php index e9c31cf..f3c41d2 100644 --- a/Form/FieldTypeHandler/IntegerHandler.php +++ b/Form/FieldTypeHandler/IntegerHandler.php @@ -51,11 +51,11 @@ protected function buildFieldForm( $min = $fieldDefinition->getValidatorConfiguration()['IntegerValueValidator']['minIntegerValue']; $max = $fieldDefinition->getValidatorConfiguration()['IntegerValueValidator']['maxIntegerValue']; - if ($min !== false) { + if ($min !== null) { $rangeConstraints['min'] = $min; } - if ($max !== false) { + if ($max !== null) { $rangeConstraints['max'] = $max; }