Skip to content

Commit 5d27f4a

Browse files
Trottdanielleadams
authored andcommitted
stream: remove unused function argument
watchClosed() is only ever called with an anonymous function for the action parameter. This anonymous funciton does not take any arguments. Remove unused argument from invocation of action(). PR-URL: #41403 Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com> Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
1 parent af6f1d5 commit 5d27f4a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/internal/webstreams/readablestream.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1332,7 +1332,7 @@ function readableStreamPipeTo(
13321332

13331333
function watchClosed(stream, promise, action) {
13341334
if (stream[kState].state === 'closed')
1335-
action(stream[kState].storedError);
1335+
action();
13361336
else
13371337
PromisePrototypeThen(promise, action, () => {});
13381338
}

0 commit comments

Comments
 (0)