From 1614ccf9cc7871749bb20ae6e36a8c6f2fc0fd9d Mon Sep 17 00:00:00 2001 From: MrOrz Date: Tue, 18 Feb 2025 04:06:45 +0800 Subject: [PATCH] fix(handlers): remove premature batch cleanup when sending reply token collector Clearing batch here would cause replies being canceled, they may think new sessions already started --- src/webhook/handlers/utils.ts | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/webhook/handlers/utils.ts b/src/webhook/handlers/utils.ts index c8841bea..03174374 100644 --- a/src/webhook/handlers/utils.ts +++ b/src/webhook/handlers/utils.ts @@ -1562,9 +1562,6 @@ async function sendReplyTokenCollector(userId: string): Promise { replyToken: tokenInfo.token, messages, }); - - // The chatbot's reply cuts off the user's input streak, thus we end the current batch here. - redis.del(getRedisBatchKey(userId)); } /**