index.js
function visitAll(state, paths, cwd, one, done) {
  var expected = paths.length
  var actual = -1
  var result = []

  paths.forEach(each)

  next()

  function each(filePath) {
    visit(state, join(cwd || '', filePath), one, onvisit)
  }

  function onvisit(files) {
    result = result.concat(files)
    next()
  }

  function next() {
    actual++

    if (actual === expected) {
      done(result)
    }
  }
}
function visitAll(state, paths, cwd, one, done) {
  var expected = paths.length
  var actual = -1
  var result = []

  paths.forEach(each)

  next()

  function each(filePath) {
    visit(state, join(cwd || '', filePath), one, onvisit)
  }

  function onvisit(files) {
    result = result.concat(files)
    next()
  }

  function next() {
    actual++

    if (actual === expected) {
      done(result)
    }
  }
}
function visitAll ( state , paths , cwd , one , done ) { var expected = paths . length var actual = - 1 var result = [ ] paths . forEach ( each ) next ( ) function each ( filePath ) { visit ( state , join ( cwd || '' , filePath ) , one , onvisit ) } function onvisit ( files ) { result = result . concat ( files ) next ( ) } function next ( ) { actual ++ if ( actual === expected ) { done ( result ) } } }
Find files in `paths`.  Returns a list of applicable files.
Find files in paths . Returns a list of applicable files .