diff --git a/src/global/actions/api/bots.ts b/src/global/actions/api/bots.ts index 419ae9d5a..c520a024e 100644 --- a/src/global/actions/api/bots.ts +++ b/src/global/actions/api/bots.ts @@ -282,7 +282,7 @@ addActionHandler('switchBotInline', (global, actions, payload) => { return undefined; } - const botSender = selectChatBot(global, message.senderId!); + const botSender = selectUser(global, message.viaBotId || message.senderId!); if (!botSender) { return undefined; }