Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
rollback: undo the last change and delete the unnecessary test
  • Loading branch information
joaoGabriel55 committed Jul 17, 2025
commit 4e040c17d2aef94f9a4c78f3ea12cba87754bccb
12 changes: 4 additions & 8 deletions lib/internal/streams/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,24 +172,20 @@ function isReadableFinished(stream, strict) {

function isReadable(stream) {
if (stream && stream[kIsReadable] != null) return stream[kIsReadable];
if (typeof stream?.readable !== 'boolean') return false;
if (typeof stream?.readable !== 'boolean') return null;
if (isDestroyed(stream)) return false;
return Boolean(
isReadableNodeStream(stream) &&
return isReadableNodeStream(stream) &&
stream.readable &&
!isReadableFinished(stream)
Comment thread
joaoGabriel55 marked this conversation as resolved.
Outdated
);
}

function isWritable(stream) {
if (stream && stream[kIsWritable] != null) return stream[kIsWritable];
if (typeof stream?.writable !== 'boolean') return false
if (typeof stream?.writable !== 'boolean') return null
Comment thread
joaoGabriel55 marked this conversation as resolved.
Outdated
if (isDestroyed(stream)) return false;
return Boolean(
isWritableNodeStream(stream) &&
return isWritableNodeStream(stream) &&
stream.writable &&
!isWritableEnded(stream)
Comment thread
joaoGabriel55 marked this conversation as resolved.
Outdated
);
}

function isFinished(stream, opts) {
Expand Down
12 changes: 0 additions & 12 deletions test/parallel/test-stream-utils.js

This file was deleted.