Skip to content

Commit

Permalink
chore: fixes regex escape characters
Browse files Browse the repository at this point in the history
  • Loading branch information
guatedude2 committed Jun 8, 2022
1 parent 5d7daa3 commit 033dda1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/build-filter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export const buildFilter = (filtersParam: string | string[]) => {
const filter = filters.shift();
filterArray.push(
`\\/?${filter
.replace(/\./g, '\\.')
.replace(/([./\\])/g, '\\$1')
.replace(/(\*?)(\*)(?!\*)/g, (match, prefix) => {
if (prefix === '*') {
return match;
Expand Down

0 comments on commit 033dda1

Please sign in to comment.