UNPKG

flixbus-api

Version:
19 lines (16 loc) 409 B
/*global module, require*/ 'use strict'; const flixbus = require('flixbus'); const store = require('../store'); module.exports = { get: function (request, response) { response.json(flixbus.find()); //response.json({ // from: request.param('from'), // to: request.param('to') //}); }, post: function (request, response) { response.json(store.get(store.put(req.body))); } };