File tree Expand file tree Collapse file tree
lib/internal/streams/iter Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -366,14 +366,14 @@ class ShareImpl {
366366 #deleteConsumerFromMin( consumer ) {
367367 if ( consumer . cursor === this . #cachedMinCursor) {
368368 this . #cachedMinCursorConsumers-- ;
369+ return this . #cachedMinCursorConsumers === 0 ;
369370 }
371+ return false ;
370372 }
371373
372374 #deleteConsumer( consumer ) {
373375 if ( this . #consumers. delete ( consumer ) ) {
374- const wasAtMin = consumer . cursor === this . #cachedMinCursor;
375- this . #deleteConsumerFromMin( consumer ) ;
376- return wasAtMin && this . #cachedMinCursorConsumers === 0 ;
376+ return this . #deleteConsumerFromMin( consumer ) ;
377377 }
378378 return false ;
379379 }
@@ -615,14 +615,14 @@ class SyncShareImpl {
615615 #deleteConsumerFromMin( consumer ) {
616616 if ( consumer . cursor === this . #cachedMinCursor) {
617617 this . #cachedMinCursorConsumers-- ;
618+ return this . #cachedMinCursorConsumers === 0 ;
618619 }
620+ return false ;
619621 }
620622
621623 #deleteConsumer( consumer ) {
622624 if ( this . #consumers. delete ( consumer ) ) {
623- const wasAtMin = consumer . cursor === this . #cachedMinCursor;
624- this . #deleteConsumerFromMin( consumer ) ;
625- return wasAtMin && this . #cachedMinCursorConsumers === 0 ;
625+ return this . #deleteConsumerFromMin( consumer ) ;
626626 }
627627 return false ;
628628 }
You can’t perform that action at this time.
0 commit comments