« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/node-utils.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/node-utils.js b/src/node-utils.js
index 8b81053d..d2e29b2f 100644
--- a/src/node-utils.js
+++ b/src/node-utils.js
@@ -83,13 +83,12 @@ export async function traverse(rootPath, {
     throw new Error(`Expected pathStyle to be device, posix, or win32`);
   }
 
-  const q_readdir = wrapQueue(readdir, Math.ceil(queueSize / 2));
-  const q_stat = wrapQueue(stat, Math.ceil(queueSize / 2));
+  const q_readdir = wrapQueue(readdir, queueSize);
 
   const recursive = (names, ...subdirectories) =>
     Promise.all(names.map(async name => {
       const devicePath = pathJoinDevice(rootPath, ...subdirectories, name);
-      const stats = await q_stat(devicePath);
+      const stats = await stat(devicePath);
 
       if (stats.isDirectory() && !filterDir(name)) return [];
       else if (stats.isFile() && !filterFile(name)) return [];