Skip to content

Commit 6142378

Browse files
Slightly cleaner code for onNext from buffer
1 parent 9fb979c commit 6142378

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/main/java/rx/internal/operators/OnSubscribeCombineLatest.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,6 @@ public void request(long n) {
138138
* This will only allow one thread at a time to do the work, but ensures via `counter` increment/decrement
139139
* that there is always once who acts on each `tick`. Same concept as used in OperationObserveOn.
140140
*/
141-
@SuppressWarnings("unchecked")
142141
void tick() {
143142
if (WIP.getAndIncrement(this) == 0) {
144143
int emitted = 0;
@@ -150,7 +149,7 @@ void tick() {
150149
if (buffer.isCompleted(o)) {
151150
child.onCompleted();
152151
} else {
153-
child.onNext(NotificationLite.<R>instance().getValue(o));
152+
buffer.accept(o, child);
154153
emitted++;
155154
requested.decrementAndGet();
156155
}

0 commit comments

Comments
 (0)