fix
This commit is contained in:
@@ -4,6 +4,7 @@ import config from "@/config";
|
||||
export default function handler(req: NextApiRequest, res: NextApiResponse) {
|
||||
if (req.method === "POST") {
|
||||
if (req.headers.token !== config.token) {
|
||||
console.log("wrong token", req.headers.token, config.token);
|
||||
res.status(403).json({ error: "wrong token" });
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user