Skip to content

Commit ffffccf

Browse files
authored
refactor(lib/find-plugins): replace regexp .exec() with .test() (#417)
1 parent 64e1641 commit ffffccf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/find-plugins.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ function processIndexDirEntryIfExists (pluginTree, { opts, dirEntries, dir, pref
8787

8888
async function processDirContents (pluginTree, { dirEntries, opts, indexDirEntry, prefix, dir, depth, currentDirHooks }) {
8989
for (const dirEntry of dirEntries) {
90-
if (opts.ignorePattern && RegExp(opts.ignorePattern).exec(dirEntry.name)) {
90+
if (opts.ignorePattern && RegExp(opts.ignorePattern).test(dirEntry.name)) {
9191
continue
9292
}
9393

0 commit comments

Comments
 (0)