Skip to content

Commit

Permalink
refactor: Fix typings issue
Browse files Browse the repository at this point in the history
  • Loading branch information
benlesh committed Jul 2, 2020
1 parent d2f6ac7 commit 166a4cf
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions compat/operator/windowTime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,13 +86,13 @@ export function windowTime<T>(this: Observable<T>,
if (isScheduler(arguments[2])) {
scheduler = arguments[2];
} else if (isNumeric(arguments[2])) {
maxWindowSize = arguments[2];
maxWindowSize = Number(arguments[2]);
}

if (isScheduler(arguments[1])) {
scheduler = arguments[1];
} else if (isNumeric(arguments[1])) {
windowCreationInterval = arguments[1];
windowCreationInterval = Number(arguments[1]);
}

return higherOrder(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler)(this) as Observable<Observable<T>>;
Expand Down
4 changes: 2 additions & 2 deletions src/internal/operators/windowTime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,13 @@ export function windowTime<T>(windowTimeSpan: number): OperatorFunction<T, Obser
if (isScheduler(arguments[2])) {
scheduler = arguments[2];
} else if (isNumeric(arguments[2])) {
maxWindowSize = arguments[2];
maxWindowSize = Number(arguments[2]);
}

if (isScheduler(arguments[1])) {
scheduler = arguments[1];
} else if (isNumeric(arguments[1])) {
windowCreationInterval = arguments[1];
windowCreationInterval = Number(arguments[1]);
}

return function windowTimeOperatorFunction(source: Observable<T>) {
Expand Down

0 comments on commit 166a4cf

Please sign in to comment.