Refactor searching

This commit is contained in:
Jonathan Cremin 2015-01-06 12:58:57 +00:00
parent 87649b5a3a
commit bbcbe8d871
9 changed files with 155 additions and 122 deletions

13
lib/services.js Normal file
View file

@ -0,0 +1,13 @@
"use strict";
var path = require('path');
var Promise = require("bluebird");
module.exports = [];
require("fs").readdirSync(path.join(__dirname, "services")).forEach(function(file) {
var service = require(path.join(__dirname, "services", file));
if (service.search) {
module.exports.push(service);
}
});