MCPcopy Create free account
hub / github.com/Bistutu/FluentRead / canAcceptMoreTasks

Function canAcceptMoreTasks

entrypoints/utils/translateQueue.ts:102–106  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

100 * 当快速扫描页面,判断是否需要暂停扫描时使用
101 */
102export function canAcceptMoreTasks(): boolean {
103 // 如果等待队列太长,返回false表示需要暂停扫描
104 const MAX_QUEUE_LENGTH = getMaxConcurrentTranslations() * 3;
105 return pendingTranslations.length < MAX_QUEUE_LENGTH;
106}

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected