Browse Source

Use autodestroy on Transform stream

Simon Detheridge 6 years ago
parent
commit
7e45a82c35
1 changed files with 1 additions and 0 deletions
  1. 1 0
      services/filestore/app/js/PersistorHelper.js

+ 1 - 0
services/filestore/app/js/PersistorHelper.js

@@ -15,6 +15,7 @@ const pipeline = promisify(Stream.pipeline)
 //   the number of bytes transferred
 //   the number of bytes transferred
 class ObserverStream extends Stream.Transform {
 class ObserverStream extends Stream.Transform {
   constructor(options) {
   constructor(options) {
+    options.autoDestroy = true
     super(options)
     super(options)
 
 
     this.bytes = 0
     this.bytes = 0