chirag04 / mail-listener2

Mail listener library for node.js. Get notification when new email arrived.
MIT License
245 stars 116 forks source link

Attachment not being downloaded #82

Closed rashthedude closed 5 years ago

rashthedude commented 5 years ago

I have set "attachments" to true and specified the directory folder "attachments/" for attachmentOptions but the file is not being downloaded. Do I have to manually create a stream and consume or what is the proper way of downloading the file?

rashthedude commented 5 years ago

I have also attempted:

var output = fs.createWriteStream(attachment.generatedFileName); attachment.stream.pipe(output);

Inside the attachment event without avail.