Skip to content

Commit 8ac77fc

Browse files
author
Contra
committed
wait for file close in writeStream
1 parent 002273c commit 8ac77fc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/createOutputStream/writeStream.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ var fs = require('graceful-fs');
33
module.exports = function(writePath, file, cb) {
44
var outStream = fs.createWriteStream(writePath);
55
file.contents.once('error', cb);
6-
outStream.once('end', function(){
6+
outStream.once('close', function(){
77
cb();
88
});
99
file.contents.pipe(outStream);

0 commit comments

Comments
 (0)