var express = require('express'); var router = express.Router(); var sports = require('../database/scores/sports'); var seasons = require('../database/scores/seasons'); router.get('/sports', function(req, res, next) { sports.retrieveAll() .then(data => res.json(data)); }); router.get('/seasons', function(req, res, next) { seasons.retrieveAll() .then(data => res.json(data)); }) module.exports = router;