mirror of
https://github.com/vlucas/valitron.git
synced 2025-12-30 23:01:52 +00:00
required-conditionals; fixing count to isset
This commit is contained in:
parent
757b07f3cd
commit
ee4abd9a5f
@ -954,7 +954,7 @@ class Validator
|
|||||||
{
|
{
|
||||||
$conditionallyReq = false;
|
$conditionallyReq = false;
|
||||||
// if we actually have conditionally required with fields to check against
|
// if we actually have conditionally required with fields to check against
|
||||||
if (count($params[0])) {
|
if (isset($params[0])) {
|
||||||
// convert single value to array if it isn't already
|
// convert single value to array if it isn't already
|
||||||
$reqParams = is_array($params[0]) ? $params[0] : array($params[0]);
|
$reqParams = is_array($params[0]) ? $params[0] : array($params[0]);
|
||||||
// check for the flag indicating if all fields are required
|
// check for the flag indicating if all fields are required
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user