Skip to content

Commit 3fb2048

Browse files
authored
Validators::isPhpIdentifier(): Value is always string. (#268)
1 parent fb6e92a commit 3fb2048

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Utils/Validators.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -355,6 +355,6 @@ public static function isType(string $type): bool
355355
*/
356356
public static function isPhpIdentifier(string $value): bool
357357
{
358-
return is_string($value) && preg_match('#^[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*$#D', $value);
358+
return preg_match('#^[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*$#D', $value) === 1;
359359
}
360360
}

0 commit comments

Comments
 (0)