Stop smooth streaming immediately on abort
| @@ -3365,7 +3365,7 @@ class StreamingProcessor { | |||
| 3365 | const timestamps = []; | 3365 | const timestamps = []; |
| 3366 | for await (const { text, swipes, logprobs, toolCalls, state } of this.generator()) { | 3366 | for await (const { text, swipes, logprobs, toolCalls, state } of this.generator()) { |
| 3367 | timestamps.push(Date.now()); | 3367 | timestamps.push(Date.now()); |
| 3368 | if (this.isStopped) { | 3368 | if (this.isStopped || this.abortController.signal.aborted) { |
| 3369 | return; | 3369 | return; |
| 3370 | } | 3370 | } |
| 3371 | 3371 | ||