File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -34,8 +34,18 @@ export const createTaskAwaitTool: ToolFactory = (config: ToolConfiguration) => {
3434 requestedIds ?? taskService . listActiveDescendantAgentTaskIds ( workspaceId ) ;
3535
3636 const uniqueTaskIds = dedupeStrings ( candidateTaskIds ) ;
37+ const bulkFilter = (
38+ taskService as unknown as {
39+ filterDescendantAgentTaskIds ?: (
40+ ancestorWorkspaceId : string ,
41+ taskIds : string [ ]
42+ ) => string [ ] ;
43+ }
44+ ) . filterDescendantAgentTaskIds ;
3745 const descendantTaskIdSet = new Set (
38- taskService . filterDescendantAgentTaskIds ( workspaceId , uniqueTaskIds )
46+ typeof bulkFilter === "function"
47+ ? bulkFilter ( workspaceId , uniqueTaskIds )
48+ : uniqueTaskIds . filter ( ( taskId ) => taskService . isDescendantAgentTask ( workspaceId , taskId ) )
3949 ) ;
4050
4151 const results = await Promise . all (
You can’t perform that action at this time.
0 commit comments