Fix message and chat owner bug

This commit is contained in:
Yang Luo
2023-05-10 22:13:36 +08:00
parent 7df043fb15
commit 3c871c38df
4 changed files with 22 additions and 8 deletions

View File

@ -122,6 +122,8 @@ func QueryAnswerStream(authToken string, question string, writer io.Writer, buil
}
}
fmt.Printf("%s", data)
// Write the streamed data as Server-Sent Events
if _, err = fmt.Fprintf(writer, "data: %s\n\n", data); err != nil {
return err