diff --git a/src/Rule.php b/src/Rule.php index f6040e2..26b28ac 100644 --- a/src/Rule.php +++ b/src/Rule.php @@ -6,6 +6,7 @@ use BackedEnum; use Brick\Math\BigNumber; +use Closure; use DateTimeInterface; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Contracts\Validation\InvokableRule; @@ -543,7 +544,7 @@ public static function exclude(): string * methods if a true boolean is passed in or the passed in closure returns true. * * @link https://laravel.com/docs/12.x/validation#rule-exclude-if - * @param bool|callable(): bool $callback + * @param bool|Closure(): bool $callback */ public static function excludeIf(mixed $callback): ExcludeIf { @@ -1101,7 +1102,7 @@ public static function prohibited(): string * passed in closure returns true. * * @link https://laravel.com/docs/12.x/validation#rule-prohibited-if - * @param bool|callable(): bool $callback + * @param bool|Closure(): bool $callback */ public static function prohibitedIf(mixed $callback): ProhibitedIf { @@ -1110,7 +1111,7 @@ public static function prohibitedIf(mixed $callback): ProhibitedIf /** * The field under validation must be empty or not present in the input data if the *anotherField* field - * is equal to "yes", "on", 1, "1", true, or "true". + * is equal to "yes", "on", 1, "1", true, or "true". */ public static function prohibitedIfAccepted(string $anotherField): string { @@ -1213,7 +1214,7 @@ public static function requiredArrayKeys(string ...$key): string * closure returns true. * * @link https://laravel.com/docs/12.x/validation#rule-required-if - * @param bool|callable(): bool $callback + * @param bool|Closure(): bool $callback */ public static function requiredIf(mixed $callback): RequiredIf { @@ -1221,7 +1222,7 @@ public static function requiredIf(mixed $callback): RequiredIf } /** - * The field under validation must be present and not empty if the *field* field is equal to "yes", "on", 1, "1", + * The field under validation must be present and not empty if the *field* field is equal to "yes", "on", 1, "1", * true, or "true". * * @link https://laravel.com/docs/12.x/validation#rule-required-if-accepted diff --git a/src/RuleSet.php b/src/RuleSet.php index a268131..0458d26 100644 --- a/src/RuleSet.php +++ b/src/RuleSet.php @@ -7,6 +7,7 @@ use ArrayIterator; use BackedEnum; use Brick\Math\BigNumber; +use Closure; use DateTimeInterface; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Validation\Rules\Password; @@ -605,7 +606,7 @@ public function exclude(): self * methods if a true boolean is passed in or the passed in closure returns true. * * @link https://laravel.com/docs/12.x/validation#rule-exclude-if - * @param bool|callable(): bool $callback + * @param bool|Closure(): bool $callback */ public function excludeIf(mixed $callback): self { @@ -1196,7 +1197,7 @@ public function prohibited(): self * passed in closure returns true. * * @link https://laravel.com/docs/12.x/validation#rule-prohibited-if - * @param bool|callable(): bool $callback + * @param bool|Closure(): bool $callback */ public function prohibitedIf(mixed $callback): self { @@ -1205,7 +1206,7 @@ public function prohibitedIf(mixed $callback): self /** * The field under validation must be empty or not present in the input data if the *anotherField* field - * is equal to "yes", "on", 1, "1", true, or "true". + * is equal to "yes", "on", 1, "1", true, or "true". */ public function prohibitedIfAccepted(string $anotherField): self { @@ -1308,7 +1309,7 @@ public function requiredArrayKeys(string ...$key): self * closure returns true. * * @link https://laravel.com/docs/12.x/validation#rule-required-if - * @param bool|callable(): bool $callback + * @param bool|Closure(): bool $callback */ public function requiredIf(mixed $callback): self { @@ -1316,7 +1317,7 @@ public function requiredIf(mixed $callback): self } /** - * The field under validation must be present and not empty if the *field* field is equal to "yes", "on", 1, "1", + * The field under validation must be present and not empty if the *field* field is equal to "yes", "on", 1, "1", * true, or "true". * * @link https://laravel.com/docs/12.x/validation#rule-required-if-accepted