76705a3fd7
See app/models/formats/README for info
18 lines
415 B
JavaScript
18 lines
415 B
JavaScript
//
|
|
// load all the formats
|
|
//
|
|
//
|
|
|
|
var formats = {}
|
|
var path = require('path');
|
|
var folder = __dirname + "/"
|
|
//"./app/models/formats/"
|
|
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;
|