Skip to content

Commit 49ed8b3

Browse files
authored
Merge pull request #15 from franzose/feat/simplify-alphadash
feat: simplify regex of the Alphadash rule
2 parents b31562d + b6c5f4b commit 49ed8b3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Rules/Core/Alphadash.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,6 @@ final class Alphadash extends AbstractRule
1414
{
1515
public function isValid(mixed $input = null): bool
1616
{
17-
return (bool) preg_match('/^([-a-z0-9_-])+$/i', $input);
17+
return (bool) preg_match('/^[a-z0-9_-]+$/i', $input);
1818
}
1919
}

0 commit comments

Comments
 (0)