fix(DialogKeywords): update file writing method and adjust WhatsApp file sending logic

This commit is contained in:
Rodrigo Rodriguez (Pragmatismo) 2025-04-19 14:36:48 -03:00
parent 333f7c4e2a
commit 81aaa4bf21
2 changed files with 2 additions and 2 deletions

View file

@ -1588,7 +1588,7 @@ export class DialogKeywords {
if (!isNaN(mobile)) {
await min.whatsAppDirectLine.sendFileToDevice(mobile, url, filename, caption, undefined, false);
await min.whatsAppDirectLine.sendFileToDevice(mobile, url, filename, caption, undefined, 0);
} else {
await min.conversationalService['sendOnConversation'](min, user, reply);
}

View file

@ -716,7 +716,7 @@ export class WhatsappDirectLine extends GBService {
return `${attachment.content.title} - ${attachment.content.text}`;
}
public async sendFileToDevice(to, url, filename, caption, chatId, isViewOnce = true) {
public async sendFileToDevice(to, url, filename, caption, chatId, isViewOnce = false) {
let options;
switch (this.provider) {
case 'meta':