From 76094bae365e1eb6d3cd892f7c60bac1b47c3972 Mon Sep 17 00:00:00 2001 From: "Brian K. Christensen" Date: Fri, 8 Jun 2018 00:31:17 +0200 Subject: [PATCH] fix: make TS type def of VirtualAction compatible with TS 2.9 --- src/scheduler/AsyncAction.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/scheduler/AsyncAction.ts b/src/scheduler/AsyncAction.ts index 20360559d8..896b87e5e5 100644 --- a/src/scheduler/AsyncAction.ts +++ b/src/scheduler/AsyncAction.ts @@ -14,10 +14,12 @@ export class AsyncAction extends Action { public state: T; public delay: number; protected pending: boolean = false; + protected work: (this: this, state?: T) => void; constructor(protected scheduler: AsyncScheduler, - protected work: (this: AsyncAction, state?: T) => void) { + work: (this: AsyncAction, state?: T) => void) { super(scheduler, work); + this.work = work; } public schedule(state?: T, delay: number = 0): Subscription {