Skip to content

Commit 70c41a8

Browse files
yashLadhatargos
authored andcommitted
stream: remove redundant context from comments
Using the variable name in the comment and justifying the type seems redundant to me and instead it should defined the entity which it is acting, like in our case it is acting as a flag to control the flow in streams. PR-URL: #35728 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Robert Nagy <ronagy@icloud.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
1 parent a41e3eb commit 70c41a8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/internal/streams/from.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,11 @@ function from(Readable, iterable, opts) {
3838
...opts
3939
});
4040

41-
// Reading boolean to protect against _read
41+
// Flag to protect against _read
4242
// being called before last iteration completion.
4343
let reading = false;
4444

45-
// needToClose boolean if iterator needs to be explicitly closed
45+
// Flag for when iterator needs to be explicitly closed.
4646
let needToClose = false;
4747

4848
readable._read = function() {

0 commit comments

Comments
 (0)