mirror of
https://github.com/vitodeploy/vito.git
synced 2025-07-03 06:56:15 +00:00
Add phpstan level 7(#544)
This commit is contained in:
@ -12,7 +12,7 @@ public function validate(string $attribute, mixed $value, Closure $fail): void
|
||||
if (! $value) {
|
||||
return;
|
||||
}
|
||||
if (preg_match("/^(?!\-)(?:[a-zA-Z\d\-]{0,62}[a-zA-Z\d]\.){1,126}(?!\d+)[a-zA-Z\d]{1,63}$/", $value) === 1) {
|
||||
if (preg_match("/^(?!\-)(?:[a-zA-Z\d\-]{0,62}[a-zA-Z\d]\.){1,126}(?!\d+)[a-zA-Z\d]{1,63}$/", (string) $value) === 1) {
|
||||
return;
|
||||
}
|
||||
$fail('Domain is not valid')->translate();
|
||||
|
Reference in New Issue
Block a user