lib/utils.js
function readDirsParallel(dirs, cb) {
  var funcs = [];
  dirs.forEach(function(dir) {
    funcs.push(readDirAbs.bind(null, dir));
  });
  async.parallel(funcs, function(err, results) {
    if (err) {
      return cb(err, null);
    }
    // Flatten results and return
    var flat = [].concat.apply([], results);
    cb(null, flat);
  }
  );
}
function readDirsParallel(dirs, cb) {
  var funcs = [];
  dirs.forEach(function(dir) {
    funcs.push(readDirAbs.bind(null, dir));
  });
  async.parallel(funcs, function(err, results) {
    if (err) {
      return cb(err, null);
    }
    // Flatten results and return
    var flat = [].concat.apply([], results);
    cb(null, flat);
  }
  );
}
function readDirsParallel ( dirs , cb ) { var funcs = [ ] ; dirs . forEach ( function ( dir ) { funcs . push ( readDirAbs . bind ( null , dir ) ) ; } ) ; async . parallel ( funcs , function ( err , results ) { if ( err ) { return cb ( err , null ) ; } // Flatten results and return var flat = [ ] . concat . apply ( [ ] , results ) ; cb ( null , flat ) ; } ) ; }
fs.readdir list of paths in parallel. used when `dir` arg is an array.
fs . readdir list of paths in parallel . used when dir arg is an array .