nisaacson / pdf-extract

Node PDF Extract
MIT License
383 stars 76 forks source link

fixed bug in process method #5

Closed alexscheelmeyer closed 10 years ago

alexscheelmeyer commented 10 years ago

The provided callback to searchable does not check for errors. Since searchable actually reports errors in addition to reporting data, this has the unfortunate consequence that the forEachSeries callback is called too many times and the file parameter to the iterator ends up as undefined. The fix is to detect the error and propagate it, not calling the async callback in that case.

nisaacson commented 10 years ago

fix published to npm as version 1.0.7