I have an Observable snippet that eventually returns an error and retries, or just returns onNext. I don't need anything on onNext, so that’s just it Observable<Unit>.
Now the problem is that at the end of the chain I have to hit this onNext and I have nothing but the old old Observable.just(). But I cannot return Observable.just (null), because it returns Nothing?, not Unit. I can not return Unitbecause it does not work. Therefore, I have Observable.just(null).map{}. It works, but it looks ugly. Any idea for a better solution?
source
share