Skip to content

Commit 28eb29b

Browse files
committed
fix
1 parent 0aa6d79 commit 28eb29b

File tree

2 files changed

+2
-16
lines changed
  • packages/service/core/workflow/dispatch
  • projects/app/src/pages/api/core/app/logs

2 files changed

+2
-16
lines changed

packages/service/core/workflow/dispatch/index.ts

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -99,16 +99,6 @@ export async function dispatchWorkFlow({
9999
apiVersion
100100
} = data;
101101

102-
const responseChatItemId = (() => {
103-
if (!!lastInteractive) {
104-
const lastAiChat = histories.findLast((item) => item.obj === ChatRoleEnum.AI);
105-
if (lastAiChat?.dataId) {
106-
return lastAiChat.dataId;
107-
}
108-
}
109-
return data.responseChatItemId;
110-
})();
111-
112102
// Check url valid
113103
const invalidInput = query.some((item) => {
114104
if (item.type === ChatItemValueTypeEnum.file && item.file?.url) {
@@ -197,8 +187,7 @@ export async function dispatchWorkFlow({
197187
...data,
198188
query,
199189
histories,
200-
timezone,
201-
responseChatItemId
190+
timezone
202191
}))
203192
};
204193
// MCP
@@ -228,7 +217,6 @@ export async function dispatchWorkFlow({
228217
// Init some props
229218
return runWorkflow({
230219
...data,
231-
responseChatItemId,
232220
checkIsStopping,
233221
query,
234222
histories,

projects/app/src/pages/api/core/app/logs/list.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,7 @@ async function handler(
141141
}
142142
},
143143
customFeedback: {
144-
$sum: {
145-
$cond: [{ $gt: [{ $size: { $ifNull: ['$customFeedbacks', []] } }, 0] }, 1, 0]
146-
}
144+
$sum: { $size: { $ifNull: ['$customFeedbacks', []] } }
147145
},
148146
errorCountFromChatItem: {
149147
$sum: {

0 commit comments

Comments
 (0)