From e08ea7f38fb03f26d897fb8fcf86e6f56f2482fe Mon Sep 17 00:00:00 2001 From: Robert Nagy Date: Sat, 10 Jul 2021 18:50:24 +0200 Subject: [PATCH] fixup --- lib/internal/streams/end-of-stream.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/internal/streams/end-of-stream.js b/lib/internal/streams/end-of-stream.js index 1550259d02de00..274c2796edd443 100644 --- a/lib/internal/streams/end-of-stream.js +++ b/lib/internal/streams/end-of-stream.js @@ -157,13 +157,13 @@ function eos(stream, options, callback) { } else if ( !readable && (!willEmitClose || isReadable(stream)) && - writableFinished + (writableFinished || !isWritable(stream)) ) { process.nextTick(onclose); } else if ( !writable && (!willEmitClose || isWritable(stream)) && - readableFinished + (readableFinished || !isReadable(stream)) ) { process.nextTick(onclose); } else if ((rState && stream.req && stream.aborted)) {