Skip to content

Commit

Permalink
Update FileRule.php
Browse files Browse the repository at this point in the history
文件验证不通过,是不是第42行少了一个"!"
  • Loading branch information
jingyifeng authored Feb 28, 2020
1 parent b701125 commit 15d3f4b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/validator/src/Rule/FileRule.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public function validate(array $data, string $propertyName, $item, $default = nu
$message = (empty($message)) ? sprintf('%s must exist!', $propertyName) : $message;
throw new ValidatorException($message);
}
if (isset($data[$propertyName])) {
if (!isset($data[$propertyName])) {
throw new ValidatorException($message);
}
foreach ($filesFields as $key => $field) {
Expand Down

0 comments on commit 15d3f4b

Please sign in to comment.