diff --git a/RxRelay/BehaviorRelay.swift b/RxRelay/BehaviorRelay.swift index 9ab2a4e92..5e745c2f5 100644 --- a/RxRelay/BehaviorRelay.swift +++ b/RxRelay/BehaviorRelay.swift @@ -44,6 +44,6 @@ public final class BehaviorRelay: ObservableType { /// /// - returns: `Infallible` public func asInfallible() -> Infallible { - asInfallible(onErrorFallbackTo: .empty()) + Infallible(self.asObservable()) } } diff --git a/RxRelay/PublishRelay.swift b/RxRelay/PublishRelay.swift index 1d9f52a1c..eadee0f43 100644 --- a/RxRelay/PublishRelay.swift +++ b/RxRelay/PublishRelay.swift @@ -38,6 +38,6 @@ public final class PublishRelay: ObservableType { /// /// - returns: `Infallible` public func asInfallible() -> Infallible { - asInfallible(onErrorFallbackTo: .empty()) + Infallible(self.asObservable()) } } diff --git a/RxRelay/ReplayRelay.swift b/RxRelay/ReplayRelay.swift index 604942de1..20931e80e 100644 --- a/RxRelay/ReplayRelay.swift +++ b/RxRelay/ReplayRelay.swift @@ -52,6 +52,6 @@ public final class ReplayRelay: ObservableType { /// /// - returns: `Infallible` public func asInfallible() -> Infallible { - asInfallible(onErrorFallbackTo: .empty()) + Infallible(self.asObservable()) } }