mirror of
https://github.com/yangjian102621/geekai.git
synced 2025-11-07 09:43:43 +08:00
fix: fixed bug for concurrency risk for getting token for chat histroy with issue #92
This commit is contained in:
@@ -634,7 +634,7 @@ const connect = function (chat_id, role_id) {
|
||||
|
||||
// 获取 token
|
||||
const reply = chatData.value[chatData.value.length - 1]
|
||||
httpPost("/api/chat/tokens", {text: "", model: getModelValue(modelID.value)}).then(res => {
|
||||
httpPost("/api/chat/tokens", {text: "", model: getModelValue(modelID.value), chat_id: chat_id}).then(res => {
|
||||
reply['created_at'] = new Date().getTime();
|
||||
reply['tokens'] = res.data;
|
||||
// 将聊天框的滚动条滑动到最底部
|
||||
|
||||
Reference in New Issue
Block a user