There was an error while loading. Please reload this page.
1 parent da4bd1e commit 7f16b09Copy full SHA for 7f16b09
lib/scan.js
@@ -5,8 +5,7 @@ var path = require('path')
5
var filter = require('patterns')([/^\./, /\/\./])
6
var debug = require('./debug')
7
8
-module.exports = function (cwd, dir) {
9
- if (!dir) dir = cwd
+module.exports = function (dir) {
10
dir = path.resolve(dir)
11
12
if (filter.match(dir)) {
@@ -21,7 +20,7 @@ module.exports = function (cwd, dir) {
21
20
if (~content.indexOf('.git')) return [dir]
22
23
return content.map(joinPathWith(dir)).filter(isDir).reduce(function (result, dir) {
24
- return result.concat(module.exports(cwd, dir))
+ return result.concat(module.exports(dir))
25
}, [])
26
}
27
0 commit comments