We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
There is nothing error with using html forms, but requests made through pinia will get 'MulterError: Unexpected field att wrappedFileFilter'
// Front-end(pinia) async postCover() { try { console.log(1); // const post_cover = this.postCover; const formData = new FormData(); formData.append('post_cover', this.cover); const res = await axios.post('/api/cover', formData, { headers: { 'Content-Type': 'multipart/form-data' } }); } catch(error) { console.log(error); } }
// back-end(node.js) const multer = require("multer"); const upload = multer({ dest: "uploads/" }); router.post("/cover", upload.single("cover"), async (req, res) => { console.log(1); res.send(req.file); });
The text was updated successfully, but these errors were encountered:
No branches or pull requests
There is nothing error with using html forms, but requests made through pinia will get 'MulterError: Unexpected field att wrappedFileFilter'
The text was updated successfully, but these errors were encountered: