[validation] Remove superfluous if-statement
This commit is contained in:
parent
e4fa963bdf
commit
4924769549
1 changed files with 1 additions and 6 deletions
|
@ -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){
|
||||
|
|
Loading…
Reference in a new issue