Remove POST from allowed HTTP methods on api server

This commit is contained in:
Essem 2021-06-29 17:49:13 -05:00
parent 2da505a778
commit 4a516329e5
No known key found for this signature in database
GPG key ID: 7D497397CC3A2A8C

View file

@ -105,7 +105,7 @@ wss.on("error", (err) => {
const httpServer = http.createServer();
httpServer.on("request", async (req, res) => {
if (req.method !== "GET" && req.method !== "POST") {
if (req.method !== "GET") {
res.statusCode = 405;
return res.end("405 Method Not Allowed");
}