Try close stream before unlink
This commit is contained in:
1 parent
bd9c0f996d
commit
760a39afb9
1 file changed
+1
@@ -223,6 +223,7 @@ export class DownloadHttpClient {
|
||||
const resetDestinationStream = async (
|
||||
fileDownloadPath: string
|
||||
): Promise<void> => {
|
||||
destinationStream.close()
|
||||
await rmFile(fileDownloadPath)
|
||||
destinationStream = fs.createWriteStream(fileDownloadPath)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user