Skip to content

Commit

Permalink
fix(IteratorObservable): clarify the return type of IteratorObservabl…
Browse files Browse the repository at this point in the history
…e.create() (#2070)

`IteratorObservable.create<T>()` now returns correctly
`Observable<T>` with supplied type parameter `T`. This fixes the previous
implementations which always returns `Observable<{}>`.
  • Loading branch information
tetsuharuohzeki authored and benlesh committed Nov 4, 2016
1 parent 0c3d4a4 commit 4f0f865
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/observable/IteratorObservable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import { Subscriber } from '../Subscriber';
export class IteratorObservable<T> extends Observable<T> {
private iterator: any;

static create<T>(iterator: any, scheduler?: Scheduler) {
static create<T>(iterator: any, scheduler?: Scheduler): IteratorObservable<T> {
return new IteratorObservable(iterator, scheduler);
}

Expand Down

0 comments on commit 4f0f865

Please sign in to comment.