@@ -97,7 +97,7 @@ routeRatingsRouter.get('/by/route/:id', async (req: Request, res: Response) => {
|
||||
* type: integer
|
||||
* example: 4
|
||||
* - in: query
|
||||
* name: h-captcha-response
|
||||
* name: hcaptcha_response
|
||||
* required: true
|
||||
* description: The hCaptcha response key
|
||||
* schema:
|
||||
@@ -108,7 +108,7 @@ routeRatingsRouter.post('/', async (req: Request, res: Response) => {
|
||||
try {
|
||||
let route_id = req.query.route_id as string;
|
||||
let stars = Number(req.query.stars);
|
||||
let captcha_token = req.query['h-captcha-response'] as string;
|
||||
let captcha_token = req.query['hcaptcha_response'] as string;
|
||||
|
||||
if (!route_id || isNaN(stars) || !captcha_token) {
|
||||
res.status(400).send({'message': 'Missing parameters'});
|
||||
|
||||
Reference in New Issue
Block a user