Fix infinite-hang bug in /api/uploadLayerImage

Oops, Next.js has built-in request body parsing that happens automatically. So it was giving us a `req.body` string, and our code to read in the body and put it in a buffer was waiting forever!

Thankfully, it's much easier than I expected to turn that behavior off for just one route. Now it works like before, so our existing code works again, ta da!
This commit is contained in:
Emi Matchu 2022-09-24 23:10:34 -07:00
parent 832747b7a8
commit 34ceb6f5b4

View file

@ -177,4 +177,10 @@ async function handleWithBeeline(req, res) {
); );
} }
export const config = {
api: {
bodyParser: false,
},
};
export default handleWithBeeline; export default handleWithBeeline;