Adjusting hcaptcha http parameter name
Jenkins Production Deployment

This commit is contained in:
2022-01-09 21:53:24 +01:00
parent 9aebd12d16
commit ac8de54d95
4 changed files with 8 additions and 8 deletions
@@ -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'});