I'm trying to save Form Data with its information but when I do so I get a weird looking object that I think the server is refusing to accept and returns a 500 error.
Here is how I'm handling it:
const formData = new FormData();
let currentlyUploaded = e.target.files[0];
formData.append(currentlyUploaded.name, currentlyUploaded);
// passing the data in function then ...
And this is how it looks when I console it later before the call, and it doesn't look correct. 
here is the route:
router.post(
`${prefix}/create-quiz`,
userAuth,
upload.single("file"),
async (req, res) => {
try {
const user = await User.findOne({ _id: req.params.userId });
const newQuiz = new Quiz({
purchaseCoins: req.body.purchaseCoins,
privacy: req.body.privacy,
created_by: req.params.userId,
category: req.body.category,
title: req.body.title,
description: req.body.description,
difficulty: req.body.difficulty,
questions: req.body.questions,
thumbnail: req.file.filename,
});
await newQuiz.save();
user.quizzes.push(newQuiz._id);
await user.save();
return res.status(201).json({
message: "Finally , quiz created properly!",
success: true,
});
} catch (error) {
// return res.status(500).json({
// message: "Can't save this quiz try again, check if it already exists",
// success: false,
// });
console.log("errorium: ", error)
}
}
);