Skip to content

Commit

Permalink
add extra backslash character code
Browse files Browse the repository at this point in the history
so it will get interpreted as a single backslash rather than the
code getting interpreted as a character.
  • Loading branch information
70ray committed Dec 28, 2024
1 parent 15d9310 commit fd5656b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pinc/unicode.inc
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ function get_unicode_regex_class($codepoint, $lang = 'php')
if ($lang == "php") {
return '\\x{' . $hex . '}';
} elseif ($lang == "js") {
return '\\u{' . $hex . '}';
return '\\\\u{' . $hex . '}';
} else {
throw new Exception("invalid lang provided: $lang");
}
Expand Down

0 comments on commit fd5656b

Please sign in to comment.