Skip to content

Commit 1e252ed

Browse files
committed
fix: fix picomatch usage
1 parent ea4ee3e commit 1e252ed

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

src/lib/fileList.js

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -310,14 +310,12 @@ async function createChildTree(parent, item, root) {
310310

311311
parent.children.push(file);
312312
if (isDirectory) {
313-
if (
314-
picomatch.isMatch(
315-
settings.value.excludeFolders,
316-
Url.join(file.path, ""),
317-
{ matchBase: true },
318-
)
319-
)
320-
return;
313+
const ignore = picomatch.isMatch(
314+
Url.join(file.path, ""),
315+
settings.value.excludeFolders,
316+
{ matchBase: true },
317+
);
318+
if (ignore) return;
321319

322320
getAllFiles(file, root);
323321
return;

0 commit comments

Comments
 (0)