diff --git a/src/models/climbing-route-rating/climbing_routes/climbingRoutes.router.ts b/src/models/climbing-route-rating/climbing_routes/climbingRoutes.router.ts index 25b48e0..9e38339 100644 --- a/src/models/climbing-route-rating/climbing_routes/climbingRoutes.router.ts +++ b/src/models/climbing-route-rating/climbing_routes/climbingRoutes.router.ts @@ -195,7 +195,7 @@ climbingRoutesRouter.get('/:id', async (req: Request, res: Response) => { */ climbingRoutesRouter.post('/', async (req: Request, res: Response) => { try { - let gym_id = Number(req.query.gym_id); + let gym_id = parseInt(req.query.gym_id as string, 10); let name = req.query.name as string; let difficulty = req.query.difficulty as string; let captcha_token = req.query['hcaptcha_response'] as string;