Skip to content

Commit b8f3ced

Browse files
DeepSpawnakarnokd
authored andcommitted
fix ReactiveX#5468: eager hooks onError call (ReactiveX#5470)
* fix ReactiveX#5468: eager hooks onError call Move the call to RxJavaHooks into the catch block, so we only report it if the underlying subscriber throws in its onError method. This brings the behaviour in line with that of SafeSubscriber, which only call Hooks.onError inside the catch * ReactiveX#5468 move hooks OnError into correct if block
1 parent 3e5b117 commit b8f3ced

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/rx/observers/SafeCompletableSubscriber.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ public void onCompleted() {
5454

5555
@Override
5656
public void onError(Throwable e) {
57-
RxJavaHooks.onError(e);
5857
if (done) {
58+
RxJavaHooks.onError(e);
5959
return;
6060
}
6161
done = true;

0 commit comments

Comments
 (0)