Commit 3411cec9 authored by wuhao's avatar wuhao 🎯

asder

parent 95825589
......@@ -6,9 +6,11 @@ import formidable from "formidable";
export default async function handler(req, res) {
if (req.method === "POST") {
const form = formidable({});
const formData = await req.formData();
// Get the file from the form data
const file = formData.get("file");
console.log("====================================");
console.log(form);
console.log(file);
console.log("====================================");
res.status(200).json({ data: "sad" });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment