Skip to content

Commit

Permalink
updated regex used to parse javascript function name
Browse files Browse the repository at this point in the history
  • Loading branch information
Athlon1600 committed Jul 28, 2020
1 parent e3a0bab commit e92b876
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/SignatureDecoder.php
Expand Up @@ -48,7 +48,7 @@ public function parseFunctionName($js_code)

return $func_name;

} else if (preg_match('@\b([a-zA-Z0-9$]{2})\s*=\s*function\(\s*a\s*\)\s*{\s*a\s*=\s*a\.split\(\s*""\s*\)@is', $js_code, $matches)) {
} else if (preg_match('@(?:\b|[^a-zA-Z0-9$])([a-zA-Z0-9$]{2})\s*=\s*function\(\s*a\s*\)\s*{\s*a\s*=\s*a\.split\(\s*""\s*\)@is', $js_code, $matches)) {
return preg_quote($matches[1]);
}

Expand Down

0 comments on commit e92b876

Please sign in to comment.