Skip to content

Commit

Permalink
refactor(concat): use mixins for next/error
Browse files Browse the repository at this point in the history
  • Loading branch information
tusharmath committed Sep 9, 2017
1 parent 0c3b7f6 commit ebe788d
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions src/operators/Concat.ts
@@ -1,3 +1,4 @@
import {ErrorNextMixin, Virgin} from '../lib/Mixins'
/**
* Created by tushar on 05/09/17.
*/
Expand All @@ -7,20 +8,14 @@ import {IScheduler} from '../lib/Scheduler'
import {CompositeSubscription, ISubscription} from '../lib/Subscription'
import {curry} from '../lib/Utils'

class ConcatObserver<T> implements IObserver<T> {
class ConcatObserver<T> extends ErrorNextMixin(Virgin) implements IObserver<T> {
constructor(
private src: IObservable<T>,
private sink: IObserver<T>,
readonly sink: IObserver<T>,
private sh: IScheduler,
private cSub: CompositeSubscription
) {}

next(val: T): void {
this.sink.next(val)
}

error(err: Error): void {
this.sink.error(err)
) {
super()
}

complete(): void {
Expand Down

0 comments on commit ebe788d

Please sign in to comment.