Closed themorganthompson closed 8 years ago
db.attachment.get(id, file, function(err, body) { if (!err) { fs.writeFile(req.file.name, body); } });
Upon opening the newly-written file, I see an error message that says, "[filename] could not be opened because it is empty."
If I make an http.get request via Postman, I can see the image fine. If I look at the attachment in Cloudant, I can see the image fine.
Upon opening the newly-written file, I see an error message that says, "[filename] could not be opened because it is empty."
If I make an http.get request via Postman, I can see the image fine. If I look at the attachment in Cloudant, I can see the image fine.