diff --git a/CHANGELOG.md b/CHANGELOG.md index 5976b8f4..64fabc81 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ ### Fixed * Fixed prefilledVariables in startTypebot +* Fix duplicate file upload # 2.1.2 (2024-10-06 10:09) diff --git a/src/api/integrations/channel/whatsapp/whatsapp.baileys.service.ts b/src/api/integrations/channel/whatsapp/whatsapp.baileys.service.ts index de088846..03a4cb67 100644 --- a/src/api/integrations/channel/whatsapp/whatsapp.baileys.service.ts +++ b/src/api/integrations/channel/whatsapp/whatsapp.baileys.service.ts @@ -2006,7 +2006,7 @@ export class BaileysStartupService extends ChannelStartupService { const mimetype = mime.getType(fileName).toString(); - const fullName = join(`${this.instance.id}`, messageRaw.key.remoteJid, mediaType, fileName); + const fullName = join(`${this.instance.id}`, messageRaw.key.remoteJid, `${messageRaw.key.id}`, mediaType, fileName); await s3Service.uploadFile(fullName, buffer, size.fileLength?.low, { 'Content-Type': mimetype,