X-Git-Url: https://git.josue.xyz/?p=dotfiles%2F.git;a=blobdiff_plain;f=.config%2Fcoc%2Fextensions%2Fnode_modules%2Fcoc-prettier%2Fnode_modules%2Frxjs%2Fsrc%2Finternal%2Foperators%2FretryWhen.ts;h=3be9fed71513d7e6ed93d12c8a78e8eaf9d67bac;hp=325742dcb6f752fb1b8f613b7b9cad81f5d098dc;hb=4d07c77cf4d78cab8639e13ddc3c22495e585b0b;hpb=b3950616b54221c40a7dab9099bda675007e5b6e diff --git a/.config/coc/extensions/node_modules/coc-prettier/node_modules/rxjs/src/internal/operators/retryWhen.ts b/.config/coc/extensions/node_modules/coc-prettier/node_modules/rxjs/src/internal/operators/retryWhen.ts index 325742dc..3be9fed7 100644 --- a/.config/coc/extensions/node_modules/coc-prettier/node_modules/rxjs/src/internal/operators/retryWhen.ts +++ b/.config/coc/extensions/node_modules/coc-prettier/node_modules/rxjs/src/internal/operators/retryWhen.ts @@ -4,11 +4,8 @@ import { Observable } from '../Observable'; import { Subject } from '../Subject'; import { Subscription } from '../Subscription'; -import { OuterSubscriber } from '../OuterSubscriber'; -import { InnerSubscriber } from '../InnerSubscriber'; -import { subscribeToResult } from '../util/subscribeToResult'; - import { MonoTypeOperatorFunction, TeardownLogic } from '../types'; +import { SimpleOuterSubscriber, innerSubscribe, SimpleInnerSubscriber } from '../innerSubscribe'; /** * Returns an Observable that mirrors the source Observable with the exception of an `error`. If the source Observable @@ -43,11 +40,11 @@ class RetryWhenOperator implements Operator { * @ignore * @extends {Ignored} */ -class RetryWhenSubscriber extends OuterSubscriber { +class RetryWhenSubscriber extends SimpleOuterSubscriber { - private errors: Subject; - private retries: Observable; - private retriesSubscription: Subscription; + private errors?: Subject; + private retries?: Observable; + private retriesSubscription?: Subscription; constructor(destination: Subscriber, private notifier: (errors: Observable) => Observable, @@ -70,10 +67,10 @@ class RetryWhenSubscriber extends OuterSubscriber { } catch (e) { return super.error(e); } - retriesSubscription = subscribeToResult(this, retries); + retriesSubscription = innerSubscribe(retries, new SimpleInnerSubscriber(this)); } else { - this.errors = null; - this.retriesSubscription = null; + this.errors = undefined; + this.retriesSubscription = undefined; } this._unsubscribeAndRecycle(); @@ -82,7 +79,7 @@ class RetryWhenSubscriber extends OuterSubscriber { this.retries = retries; this.retriesSubscription = retriesSubscription; - errors.next(err); + errors!.next(err); } } @@ -91,21 +88,19 @@ class RetryWhenSubscriber extends OuterSubscriber { const { errors, retriesSubscription } = this; if (errors) { errors.unsubscribe(); - this.errors = null; + this.errors = undefined; } if (retriesSubscription) { retriesSubscription.unsubscribe(); - this.retriesSubscription = null; + this.retriesSubscription = undefined; } - this.retries = null; + this.retries = undefined; } - notifyNext(outerValue: T, innerValue: R, - outerIndex: number, innerIndex: number, - innerSub: InnerSubscriber): void { + notifyNext(): void { const { _unsubscribe } = this; - this._unsubscribe = null; + this._unsubscribe = null!; this._unsubscribeAndRecycle(); this._unsubscribe = _unsubscribe;