fix(telegram): preserve DM topic threadId in deliveryContext
When receiving messages in Telegram DM topics (Topics in Private Chats), the threadId was not saved in the session's deliveryContext, causing replies to go to General chat instead of the topic. Now we pass threadId to updateLastRoute for DM topics. Fixes #8891
This commit is contained in:
@@ -637,6 +637,8 @@ export const buildTelegramMessageContext = async ({
|
||||
channel: "telegram",
|
||||
to: String(chatId),
|
||||
accountId: route.accountId,
|
||||
// Preserve DM topic threadId for replies (fixes #8891)
|
||||
threadId: dmThreadId != null ? String(dmThreadId) : undefined,
|
||||
}
|
||||
: undefined,
|
||||
onRecordError: (err) => {
|
||||
|
||||
Reference in New Issue
Block a user