![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/vreg/node_modules/rxjs/_esm2015/internal/ |
import { Subject } from './Subject'; import { Subscription } from './Subscription'; export class AsyncSubject extends Subject { constructor() { super(...arguments); this.value = null; this.hasNext = false; this.hasCompleted = false; } _subscribe(subscriber) { if (this.hasError) { subscriber.error(this.thrownError); return Subscription.EMPTY; } else if (this.hasCompleted && this.hasNext) { subscriber.next(this.value); subscriber.complete(); return Subscription.EMPTY; } return super._subscribe(subscriber); } next(value) { if (!this.hasCompleted) { this.value = value; this.hasNext = true; } } error(error) { if (!this.hasCompleted) { super.error(error); } } complete() { this.hasCompleted = true; if (this.hasNext) { super.next(this.value); } super.complete(); } } //# sourceMappingURL=AsyncSubject.js.map