Merge pull request #951 from lucas-tomasi/patch-1

Fix duplicate file upload
This commit is contained in:
Davidson Gomes 2024-10-07 10:41:10 -03:00 committed by GitHub
commit a0a62b997c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1992,7 +1992,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,