This commit is contained in:
Zhang Minghan 2023-10-24 20:47:13 +08:00
parent 205cdc1400
commit 5e67bd49e0

View File

@ -5,6 +5,7 @@ import (
"chat/globals"
"chat/utils"
"database/sql"
"fmt"
"log"
)
@ -33,6 +34,7 @@ func (c *Conversation) SaveConversation(db *sql.DB) bool {
_, err = stmt.Exec(c.UserID, c.Id, c.Name, data, c.Model)
if err != nil {
fmt.Println(fmt.Sprintf("execute error during save conversation: %s", err.Error()))
return false
}
return true