You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
public static <S, T> Observable<T> create(AsyncOnSubscribe<S, T> asyncOnSubscribe) {
177
-
return new Observable<T>(hook.onCreate(asyncOnSubscribe));
175
+
return create((OnSubscribe<T>)asyncOnSubscribe);
178
176
}
179
177
180
178
/**
@@ -250,7 +248,7 @@ public void call(Subscriber<? super T> subscriber) {
250
248
* @see <a href="https://github.com/ReactiveX/RxJava/wiki/Implementing-Your-Own-Operators">RxJava wiki: Implementing Your Own Operators</a>
251
249
*/
252
250
public final <R> Observable<R> lift(final Operator<? extends R, ? super T> operator) {
253
-
return new Observable<R>(new OnSubscribeLift<T, R>(onSubscribe, operator));
// if this happens it means the onError itself failed (perhaps an invalid function implementation)
9015
9013
// so we are unable to propagate the error correctly and will just throw
9016
9014
RuntimeException r = new RuntimeException("Error occurred attempting to subscribe [" + e.getMessage() + "] and then again while trying to pass to onError.", e2);
9017
9015
// TODO could the hook be the cause of the error in the on error handling.
9018
-
hook.onSubscribeError(r);
9016
+
RxJavaHooks.onObservableError(r);
9019
9017
// TODO why aren't we throwing the hook's return value.
// if this happens it means the onError itself failed (perhaps an invalid function implementation)
9112
9110
// so we are unable to propagate the error correctly and will just throw
9113
9111
RuntimeException r = new OnErrorFailedException("Error occurred attempting to subscribe [" + e.getMessage() + "] and then again while trying to pass to onError.", e2);
9114
9112
// TODO could the hook be the cause of the error in the on error handling.
9115
-
hook.onSubscribeError(r);
9113
+
RxJavaHooks.onObservableError(r);
9116
9114
// TODO why aren't we throwing the hook's return value.
0 commit comments