Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f7f8818

Browse files
Update src/Symfony/Component/Validator/Constraints/MacAddressValidator.php
Co-authored-by: Nicolas Grekas <[email protected]>
1 parent fb2b16b commit f7f8818

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/Validator/Constraints/MacAddressValidator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ private static function isUnicast(string $mac): bool
6666
*/
6767
private static function isLocal(string $mac): bool
6868
{
69-
return match (substr(self::sanitize($mac), 1, 1)) {
69+
return match (self::sanitize($mac)[1]) {
7070
'2', '6', 'a', 'e', '3', '7', 'b', 'f' => true,
7171
default => false,
7272
};

0 commit comments

Comments
 (0)