mirror of
https://github.com/matthiasmullie/minify.git
synced 2025-02-23 01:52:36 +01:00
parent
023c6bfb19
commit
cb1450437c
@ -238,7 +238,7 @@ class JS extends Minify
|
|||||||
// closing the regex)
|
// closing the regex)
|
||||||
// then also ignore bare `/` inside `[]`, where they don't need to be
|
// then also ignore bare `/` inside `[]`, where they don't need to be
|
||||||
// escaped: anything inside `[]` can be ignored safely
|
// escaped: anything inside `[]` can be ignored safely
|
||||||
$pattern = '\\/([^\\[\\/\\\\]*+|(\\\\.)*+|\\[([^\\]\\\\]|\\\\.)*\\])+\\/[gimy]*';
|
$pattern = '\\/(?:[^\\[\\/\\\\]+|(?:\\\\.)+|(?:\\[(?:[^\\]\\\\]+|(?:\\\\.)+)+\\])+)++\\/[gimy]*';
|
||||||
|
|
||||||
// a regular expression can only be followed by a few operators or some
|
// a regular expression can only be followed by a few operators or some
|
||||||
// of the RegExp methods (a `\` followed by a variable or value is
|
// of the RegExp methods (a `\` followed by a variable or value is
|
||||||
|
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user