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 {