Skip to content

Commit 82537e5

Browse files
committed
update
1 parent 2569af1 commit 82537e5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Validator/UrlValidator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public function message(string $message): self
1414

1515
public function validate(string $value): string
1616
{
17-
if (!str_starts_with(strtolower($value), 'http')) {
17+
if (!preg_match('/^https?:\/\//', strtolower($value))) {
1818
return $this->message;
1919
}
2020
return !filter_var($value, FILTER_VALIDATE_URL) ? $this->message : '';

0 commit comments

Comments
 (0)