soldair / node-walkdir

Walk a directory tree emitting events based on the contents. API compatable with node-findit. Walk a tree of any depth. Fast! Handles permission errors. Stoppable. windows support. Pull requests are awesome. watchers are appreciated.
MIT License
131 stars 22 forks source link

emitting 'fail' on directories with 0 files #3

Closed justinfreitag-zz closed 12 years ago

justinfreitag-zz commented 12 years ago

From line #109

 if (err || !files || !files.length) {
        emitter.emit('fail',path,err);
        return;
 }

Is this behaviour desired?

soldair commented 12 years ago

Not desired. Thanks! Patch in the morning. On Jun 17, 2012 12:57 AM, "justinfreitag" < reply@reply.github.com> wrote:

From line #109

 if (err || !files || !files.length) {
       emitter.emit('fail',path,err);
       return;
 }

Is this behaviour desired?


Reply to this email directly or view it on GitHub: https://github.com/soldair/node-walkdir/issues/3

soldair commented 12 years ago

ok i merged your commit with master and added tests. published in walkdir@0.0.4

justinfreitag-zz commented 12 years ago

cool, thanks.