1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
'use strict'; // module PursLoader.Glob var glob = require('glob'); var async = require('async'); function globAllFn(patterns, errback, callback) { return function(){ async.map(patterns, glob, function(error, result){ if (error) errback(new Error(error))(); else callback(result)(); }); }; } exports.globAllFn = globAllFn;