Skip to content

Commit

Permalink
Fixed #18
Browse files Browse the repository at this point in the history
  • Loading branch information
zont committed Feb 12, 2014
1 parent 23de634 commit 4298506
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,13 @@ module.exports = function (options) {

function write(files, processor, callback) {
if (processor) {
var stream = processor;
stream.on('data', callback);
processor.on('data', callback);

files.forEach(function(file) {
stream.write(file);
processor.write(file);
});
stream.end();

processor.removeListener('data', callback);
}
else
files.forEach(callback);
Expand Down

0 comments on commit 4298506

Please sign in to comment.