Skip to content

Commit baabee5

Browse files
committed
regexp: replaced $ with more safe \z
1 parent 4a76916 commit baabee5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/PhpGenerator/Helpers.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ public static function formatMember($name)
188188
*/
189189
public static function isIdentifier($value)
190190
{
191-
return is_string($value) && preg_match('#^' . self::PHP_IDENT . '$#', $value);
191+
return is_string($value) && preg_match('#^' . self::PHP_IDENT . '\z#', $value);
192192
}
193193

194194

0 commit comments

Comments
 (0)