Skip to content

Commit ba96ff0

Browse files
authored
Merge pull request #1300 from mathjax/fix/pack
Fix regex for quoting file names to include
2 parents 3fc3801 + efe57da commit ba96ff0

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

components/bin/pack

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ const bundle = (process.argv[3] || 'bundle');
4242
* @return {RegExp} The regular expression for the name,
4343
*/
4444
function fileRegExp(name) {
45-
return new RegExp(name.replace(/([\\.{}[\]()?*^$])/g, '\\$1'), 'g');
45+
return new RegExp(name.replace(/([\\.{}[\]()?*+^$])/g, '\\$1'), 'g');
4646
}
4747

4848
/**

components/webpack.common.cjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ const DIRNAME = __dirname;
3535
* @return {string} The string with regex special characters escaped
3636
*/
3737
function quoteRE(string) {
38-
return string.replace(/([\\.{}[\]()?*^$])/g, '\\$1');
38+
return string.replace(/([\\.{}[\]()?*+^$])/g, '\\$1');
3939
}
4040

4141
/****************************************************************/

0 commit comments

Comments
 (0)