MCPcopy Create free account
hub / github.com/dresende/node-orm2 / fileLoader

Function fileLoader

lib/ORM.js:42–53  ·  view source on GitHub ↗
(filePaths, cb)

Source from the content-addressed store, hash-verified

40};
41
42var fileLoader = function (filePaths, cb) {
43 var self = this;
44 var iterator = function (filePath, cb) {
45 try {
46 require(filePath)(self, cb);
47 } catch (err) {
48 return cb(err)
49 }
50 };
51
52 async.eachSeries(filePaths, iterator, cb);
53};
54
55exports.connect = function (opts, cb) {
56 if (arguments.length === 0 || !opts || !optsChecker(opts)) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected