CartoDB-SQL-API/app/controllers/version_controller.js
2019-10-01 11:11:19 +02:00

18 lines
347 B
JavaScript

'use strict';
const versions = {
cartodb_sql_api: require('./../../package.json').version
};
module.exports = class VersionController {
route (app) {
app.get(`${global.settings.base_url}/version`, version());
}
};
function version () {
return function versionMiddleware (req, res) {
res.send(versions);
};
}