From 16a0e6b18eed142eacea29663a44ec14f8031cad Mon Sep 17 00:00:00 2001 From: Judson Cairo Date: Thu, 5 Sep 2024 09:28:57 -0300 Subject: [PATCH] Fix chatwoot not mentioning the quoted message --- .../integrations/chatbot/chatwoot/services/chatwoot.service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/integrations/chatbot/chatwoot/services/chatwoot.service.ts b/src/api/integrations/chatbot/chatwoot/services/chatwoot.service.ts index 27968f47..8e20b93c 100644 --- a/src/api/integrations/chatbot/chatwoot/services/chatwoot.service.ts +++ b/src/api/integrations/chatbot/chatwoot/services/chatwoot.service.ts @@ -1477,7 +1477,7 @@ export class ChatwootService { let inReplyToExternalId = null; if (msg) { - inReplyToExternalId = msg.message?.extendedTextMessage?.contextInfo?.stanzaId; + inReplyToExternalId = msg.message?.extendedTextMessage?.contextInfo?.stanzaId ?? msg.contextInfo?.stanzaId; if (inReplyToExternalId) { const message = await this.getMessageByKeyId(instance, inReplyToExternalId); if (message?.chatwootMessageId) {