Skip to content

Commit bf52382

Browse files
陈刚MylesBorins
陈刚
authored andcommitted
stream: simplify src._readableState to state
PR-URL: #18264 Reviewed-By: Weijia Wang <starkwang@126.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
1 parent 6f3fb46 commit bf52382

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/_stream_readable.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -645,8 +645,8 @@ Readable.prototype.pipe = function(dest, pipeOpts) {
645645
if (((state.pipesCount === 1 && state.pipes === dest) ||
646646
(state.pipesCount > 1 && state.pipes.indexOf(dest) !== -1)) &&
647647
!cleanedUp) {
648-
debug('false write response, pause', src._readableState.awaitDrain);
649-
src._readableState.awaitDrain++;
648+
debug('false write response, pause', state.awaitDrain);
649+
state.awaitDrain++;
650650
increasedAwaitDrain = true;
651651
}
652652
src.pause();

0 commit comments

Comments
 (0)