Skip to content

Commit 0714d8f

Browse files
octo-patchocto-patch
andcommitted
fix: pass quoted option in audioWhatsapp to support replies (fixes #2485)
The `audioWhatsapp` method was not forwarding `data.quoted` to `sendMessageWithTyping`, so audio messages sent with a `quoted` key were delivered as standalone messages instead of replies. Added `quoted: data?.quoted` to the options object in both `sendMessageWithTyping` call sites inside `audioWhatsapp` (the encoding path and the direct path), matching the pattern used by all other message-sending methods (textMessage, pollMessage, etc.). Co-Authored-By: Octopus <liyuan851277048@icloud.com>
1 parent cd800f2 commit 0714d8f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/api/integrations/channel/whatsapp/whatsapp.baileys.service.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3224,7 +3224,7 @@ export class BaileysStartupService extends ChannelStartupService {
32243224
const result = this.sendMessageWithTyping<AnyMessageContent>(
32253225
data.number,
32263226
{ audio: convert, ptt: true, mimetype: 'audio/ogg; codecs=opus' },
3227-
{ presence: 'recording', delay: data?.delay },
3227+
{ presence: 'recording', delay: data?.delay, quoted: data?.quoted },
32283228
isIntegration,
32293229
);
32303230

@@ -3241,7 +3241,7 @@ export class BaileysStartupService extends ChannelStartupService {
32413241
ptt: true,
32423242
mimetype: 'audio/ogg; codecs=opus',
32433243
},
3244-
{ presence: 'recording', delay: data?.delay },
3244+
{ presence: 'recording', delay: data?.delay, quoted: data?.quoted },
32453245
isIntegration,
32463246
);
32473247
}

0 commit comments

Comments
 (0)