Skip to content

Commit 75fa787

Browse files
committed
Allow slash in filename regex
1 parent a9fc7f4 commit 75fa787

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

middleware.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ module.exports = function(compiler, options) {
2424
var str = options.filename
2525
.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&")
2626
.replace(/\\\[[a-z]+\\\]/ig, ".+");
27-
options.filename = new RegExp("^" + str + "$");
27+
options.filename = new RegExp("^[\/]{0,1}" + str + "$");
2828
}
2929
}
3030

0 commit comments

Comments
 (0)