CartoDB-SQL-API/app/models/formats/index.js
2014-08-02 20:26:01 +02:00

17 lines
389 B
JavaScript

//
// load all the formats
//
var formats = {},
path = require('path'),
folder = __dirname + "/";
require("fs").readdirSync(folder).forEach(function(file) {
if (path.extname(file) === '.js' && file !== 'index.js' && file !== 'ogr.js' && file !== 'pg.js' ) {
var format = require(folder + file);
formats[format.prototype.id] = format;
}
});
module.exports = formats;