Skip to content

Commit

Permalink
fixup: ERR_STREAM_PREMATURE_CLOSE
Browse files Browse the repository at this point in the history
  • Loading branch information
ronag committed Sep 27, 2019
1 parent a09c43c commit 4eceeba
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 14 deletions.
8 changes: 3 additions & 5 deletions doc/api/stream.md
Original file line number Diff line number Diff line change
Expand Up @@ -1590,11 +1590,9 @@ async function run() {
run().catch(console.error);
```

On completion or error `stream.pipeline()` will call `stream.destroy(err)` on
all provided stream except for `Readable` streams which have emitted `'end'`
or `'close'` and `Writable` streams which have emitted `'finish'` or `'close'`.
Unless `autoDestroy` is enabled these streams will not be automatically cleaned
up.
`stream.pipeline()` will call `stream.destroy(err)` on all streams except:
- `Readable` streams which have emitted `'end'` or `'close'`.
- `Writable` streams which have emitted `'finish'` or `'close'`.

`stream.pipeline()` leaves dangling event listeners on the streams
after the `callback` has been invoked. In the case of reuse of streams after
Expand Down
9 changes: 0 additions & 9 deletions test.js

This file was deleted.

0 comments on commit 4eceeba

Please sign in to comment.