mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-26 06:20:53 +00:00
move pipe after error handler setup
This commit is contained in:
parent
7e9f8b885b
commit
8ebbacee5a
1 changed files with 1 additions and 1 deletions
|
@ -14,7 +14,6 @@ module.exports =
|
|||
fsPath = @_getPath(key)
|
||||
logger.log fsPath:fsPath, "writing file locally"
|
||||
writeStream = fs.createWriteStream(fsPath)
|
||||
stream.pipe writeStream
|
||||
writeStream.on "finish", ->
|
||||
timer.done()
|
||||
logger.log fsPath:fsPath, "finished writing file locally"
|
||||
|
@ -25,6 +24,7 @@ module.exports =
|
|||
stream.on "error", (err)->
|
||||
logger.log err:err, fsPath:fsPath, "problem writing file locally, with read stream"
|
||||
callback err
|
||||
stream.pipe writeStream
|
||||
|
||||
deleteFile: (fsPath, callback)->
|
||||
logger.log fsPath:fsPath, "removing local temp file"
|
||||
|
|
Loading…
Reference in a new issue