Remove test instructions, fix CORS for DELETE method
[vchess.git] / server / routes / challenges.js
index b1e0694..40c50ec 100644 (file)
@@ -65,7 +65,7 @@ router.post("/challenges", access.logged, access.ajax, (req,res) => {
 //}
 
 router.delete("/challenges", access.logged, access.ajax, (req,res) => {
-  const cid = req.query.cid;
+  const cid = req.query.id;
   ChallengeModel.remove(cid, req.userId, err => {
     res.json(err || {});
   });