Reputation: 1
I have been trying to read multipart/mixed data in nodejs.
I have tried using bodyparser
, busboy-connect
, and few other modules but nothing seems to parse this data into req.body
.
So if someone has any idea about how to implement this please leave an answer below. Thank you.
Upvotes: 0
Views: 429
Reputation: 1
app.use(myMiddleware);
function myMiddleware(req, res, next) {
req.rawBody = req.body;
if (req.headers["content-type"] === "multipart/mixed") {
req.body = req.body;
}
next();
}
Upvotes: -1