router.get('/', async(function (req, res) { try { const matches = await(MatchManager.getMatches()); res.status(200); res.json(matches.map((match) => match.toObject())); } catch (error) { res.status(error.status()); res.json(error.toJSON()); } }));
router.get('/', async(function (req, res) { try { const matches = await(MatchManager.getMatches()); res.status(200); res.json(matches.map((match) => match.toObject())); } catch (error) { res.status(error.status()); res.json(error.toJSON()); } }));