diff --git a/lib/validation.php b/lib/validation.php index 69f91a0..e405b7c 100644 --- a/lib/validation.php +++ b/lib/validation.php @@ -28,12 +28,7 @@ function validateData(&$data, $parameters){ }; $validateCheckboxValue = function($value){ - $filteredValue = filter_var($value, FILTER_VALIDATE_BOOLEAN, FILTER_NULL_ON_FAILURE); - - if(is_null($filteredValue)) - return null; - - return $filteredValue; + return filter_var($value, FILTER_VALIDATE_BOOLEAN, FILTER_NULL_ON_FAILURE); }; $validateListValue = function($value, $expectedValues){