Skip to content

Commit

Permalink
fix: Added filename for sendFile when is using path or URL (fix #1168)
Browse files Browse the repository at this point in the history
  • Loading branch information
edgardmessias committed Jun 11, 2022
1 parent 62e05c9 commit 5534fad
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/api/layers/sender.layer.ts
Expand Up @@ -618,6 +618,10 @@ export class SenderLayer extends ListenerLayer {
if (fileContent) {
base64 = fileContent;
}

if (!options.filename) {
options.filename = path.basename(pathOrBase64);
}
}

if (!base64) {
Expand Down

0 comments on commit 5534fad

Please sign in to comment.