From 95b79ca36465d50177b575ac9cf48265ccb1961e Mon Sep 17 00:00:00 2001 From: greysoh Date: Thu, 9 May 2024 11:18:56 -0400 Subject: [PATCH] chore: Remove unneeded code from passyfire routes. --- .../backendimpl/passyfire-reimpl/routes.ts | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/api/src/backendimpl/passyfire-reimpl/routes.ts b/api/src/backendimpl/passyfire-reimpl/routes.ts index 2961483..4519a87 100644 --- a/api/src/backendimpl/passyfire-reimpl/routes.ts +++ b/api/src/backendimpl/passyfire-reimpl/routes.ts @@ -47,25 +47,6 @@ export function route(instance: PassyFireBackendProvider) { for (const spoofedRoute of unsupportedSpoofedRoutes) { fastify.post(spoofedRoute, (req, res) => { - if (typeof req.body != "string") - return res.status(400).send({ - error: "Invalid token", - }); - - try { - JSON.parse(req.body); - } catch (e) { - return res.status(400).send({ - error: "Invalid token", - }); - } - - // @ts-ignore - if (!req.body.token) - return res.status(400).send({ - error: "Invalid token", - }); - return res.status(403).send({ error: "Invalid scope(s)", });