MCPcopy Create free account
hub / github.com/Acode-Foundation/Acode / pump

Function pump

src/sidebarApps/searchInFiles/worker.js:58–65  ·  view source on GitHub ↗

* Starts more file reads without flooding the main thread.

()

Source from the content-addressed store, hash-verified

56 * Starts more file reads without flooding the main thread.
57 */
58 function pump() {
59 pumpScheduled = false;
60 while (active < MAX_CONCURRENT_FILE_READS && cursor < total) {
61 const file = files[cursor++];
62 active += 1;
63 processFile(file);
64 }
65 }
66
67 function schedulePump() {
68 if (pumpScheduled) return;

Callers 1

processFilesFunction · 0.85

Calls 1

processFileFunction · 0.70

Tested by

no test coverage detected