We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fe1a93d commit 811e369Copy full SHA for 811e369
src/api/integrations/chatbot/chatwoot/services/chatwoot.service.ts
@@ -2100,10 +2100,10 @@ export class ChatwootService {
2100
const nameFile = `${random}.${mimeTypes.extension(mimeType)}`;
2101
const fileData = Buffer.from(imgBuffer.data, 'binary');
2102
2103
- const img = await Jimp.fromBuffer(fileData);
2104
- img.cover(320, 180);
+ const img = await Jimp.read(fileData);
+ await img.cover(320, 180);
2105
2106
- const processedBuffer = await img.getBuffer('image/png');
+ const processedBuffer = await img.getBufferAsync(Jimp.MIME_PNG);
2107
2108
const fileStream = new Readable();
2109
fileStream._read = () => {}; // _read is required but you can noop it
0 commit comments