提交 a0fce799 编写于 作者: R Rachel Macfarlane

Fixes #50828, code-insiders --status triggered exception in main process

上级 c8ff4489
......@@ -116,32 +116,32 @@ export function collectWorkspaceStats(folder: string, filter: string[]): Promise
if (--pending === 0) {
return done(results);
}
}
if (stats.isDirectory()) {
if (filter.indexOf(file) === -1) {
walk(join(dir, file), filter, token, (res: string[]) => {
results = results.concat(res);
} else {
if (stats.isDirectory()) {
if (filter.indexOf(file) === -1) {
walk(join(dir, file), filter, token, (res: string[]) => {
results = results.concat(res);
if (--pending === 0) {
return done(results);
}
});
} else {
if (--pending === 0) {
return done(results);
done(results);
}
});
}
} else {
if (--pending === 0) {
done(results);
if (token.count >= MAX_FILES) {
token.maxReached = true;
}
}
} else {
if (token.count >= MAX_FILES) {
token.maxReached = true;
}
token.count++;
results.push(file);
token.count++;
results.push(file);
if (--pending === 0) {
done(results);
if (--pending === 0) {
done(results);
}
}
}
});
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册