From e20f2c24ff55816dc532a51beb88e4f9c068c6ab Mon Sep 17 00:00:00 2001 From: NK Date: Sun, 5 Mar 2023 01:58:46 +0000 Subject: [PATCH] no json --- pages/api/skyblock.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/pages/api/skyblock.js b/pages/api/skyblock.js index 7ab0fda..c74b2b1 100644 --- a/pages/api/skyblock.js +++ b/pages/api/skyblock.js @@ -13,12 +13,7 @@ export default async function handler(req, res) { } console.log(req.body); let dat; - try { - dat = JSON.parse(req.body).ByteData || req.body.ByteData; - } catch (e) { - res.status(400).json({error: "ByteData is not a string or undefined"}); - return; - } + dat = req.body; if (typeof dat !== "string" || typeof dat == "undefined") { res.status(400).json({error: "ByteData is not a string or undefined"}); return;