chore: Remove unneeded code from passyfire routes.

This commit is contained in:
greysoh 2024-05-09 11:18:56 -04:00
parent 1ece50ce28
commit 95b79ca364
Signed by: imterah
GPG key ID: 8FA7DD57BA6CEA37

View file

@ -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)",
});