Skip to content

Commit 1c3b8b4

Browse files
Update the lastGlobalApiRequestTime after the AI api request is done to respect the user's specified rate limit.
1 parent 80f0f3a commit 1c3b8b4

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/core/task/Task.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2988,6 +2988,7 @@ export class Task extends EventEmitter<TaskEvents> implements TaskLike {
29882988
// effectively passes along all subsequent chunks from the original
29892989
// stream.
29902990
yield* iterator
2991+
Task.lastGlobalApiRequestTime = performance.now()
29912992
}
29922993

29932994
// Checkpoints

0 commit comments

Comments
 (0)