Skip to content

Commit 2bdb36c

Browse files
committed
cs-fix
1 parent 0dbd648 commit 2bdb36c

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

system/Validation/Rules.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,8 @@ public function required_without($str = null, ?string $fields = null, array $dat
296296
return true;
297297
}
298298

299+
$nowKeyField = 0;
300+
299301
if (strpos($keyField, '.') !== false) {
300302
$keyFieldArray = explode('.', $keyField);
301303
$nowKeyField = $keyFieldArray[1];
@@ -315,7 +317,7 @@ public function required_without($str = null, ?string $fields = null, array $dat
315317
$nowField = str_replace('*', $nowKeyField, $field);
316318
$nowFieldVaule = dot_array_search($nowField, $data);
317319

318-
return (bool) (null !== $nowFieldVaule);
320+
return null !== $nowFieldVaule;
319321
}
320322
}
321323

0 commit comments

Comments
 (0)