Skip to content

Commit 470c4cd

Browse files
committed
Merge pull request #4 from fubupc/fix-filename-regex
Bugfix: fix regex mismatching empty space after sourceMappingURL issue.
2 parents cfad381 + d57afda commit 470c4cd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ var path = require("path");
88
var async = require("async");
99
var loaderUtils = require("loader-utils");
1010

11-
var baseRegex = "\\s*[@#]\\s*sourceMappingURL\\s*=\\s*(.*)",
11+
var baseRegex = "\\s*[@#]\\s*sourceMappingURL\\s*=\\s*([^\\s]*)",
1212
// Matches /* ... */ comments
1313
regex1 = new RegExp("/\\*"+baseRegex+"\\s*\\*/"),
1414
// Matches // .... comments

0 commit comments

Comments
 (0)