Skip to content

Commit

Permalink
fix(whatsapp.gblib): SEND FILE sending bug.
Browse files Browse the repository at this point in the history
  • Loading branch information
rodrigorodriguez committed Aug 6, 2022
1 parent 08607e4 commit 7eeadfa
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions packages/whatsapp.gblib/services/WhatsappDirectLine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,16 @@ export class WhatsappDirectLine extends GBService {
from = req.body.messages[0].author.split('@')[0];
fromName = req.body.messages[0].senderName;

if (message.type !== 'chat') {
attachments = [];
attachments.push(
{
name: 'uploaded',
contentType: 'application/octet-stream',
contentUrl: message.body
});
}

if (req.body.messages[0].fromMe) {
res.end();

Expand Down

0 comments on commit 7eeadfa

Please sign in to comment.