Revert "Correção com chatwoot"

This reverts commit f58e792506.
This commit is contained in:
Victor Calazans 2025-07-09 22:38:29 -03:00
parent fe1a93da10
commit 811e369c99

View File

@ -2100,10 +2100,10 @@ export class ChatwootService {
const nameFile = `${random}.${mimeTypes.extension(mimeType)}`;
const fileData = Buffer.from(imgBuffer.data, 'binary');
const img = await Jimp.fromBuffer(fileData);
img.cover(320, 180);
const img = await Jimp.read(fileData);
await img.cover(320, 180);
const processedBuffer = await img.getBuffer('image/png');
const processedBuffer = await img.getBufferAsync(Jimp.MIME_PNG);
const fileStream = new Readable();
fileStream._read = () => {}; // _read is required but you can noop it