chore: wont parse finished result

This commit is contained in:
Yidadaa 2023-05-18 02:09:05 +08:00
parent 5f2745c32a
commit 85445c4ef2

View File

@ -123,7 +123,7 @@ export class ChatGPTApi implements LLMApi {
}
},
onmessage(msg) {
if (msg.data === "[DONE]") {
if (msg.data === "[DONE]" || finished) {
return finish();
}
const text = msg.data;