Skip to content
This repository has been archived by the owner on Jun 3, 2024. It is now read-only.

Commit

Permalink
fix: close write steam on finish
Browse files Browse the repository at this point in the history
  • Loading branch information
develar authored and Stephen Solka committed Oct 5, 2016
1 parent 361b369 commit f0c1552
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/util/httpRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ function doDownload(url: string, destination: string, redirectCount: number, opt
.pipe(fileOut)
}

fileOut.on("finish", callback)
fileOut.on("finish", () => (<any>fileOut.close)(callback))
})
.catch(callback)

Expand Down

0 comments on commit f0c1552

Please sign in to comment.