Untitled
unknown
plain_text
a year ago
546 B
5
Indexable
const getInProgressController = async (req: Request, res: Response) => { const { inProgress } = req.query; const inProgressBoolean = inProgress === 'true'; const matches = await matchesService.getInProgress(inProgressBoolean); return res.status(200).json(matches); }; const getAllMatchesController = async (req: Request, res: Response) => { const { inProgress } = req.query; if (inProgress) return getInProgressController(req, res); const matches = await matchesService.getAllMatches(); return res.status(200).json(matches); };
Editor is loading...
Leave a Comment