From b8a2744805bba19eb8a8b7db6addda8f32fca0bc Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 16 Mar 2016 16:49:04 +0100 Subject: [PATCH] allow for Delayer recursion fixes #4071 --- src/vs/base/common/async.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/vs/base/common/async.ts b/src/vs/base/common/async.ts index 1e7e03c656e..e69567ee792 100644 --- a/src/vs/base/common/async.ts +++ b/src/vs/base/common/async.ts @@ -157,11 +157,10 @@ export class Delayer { }).then(() => { this.completionPromise = null; this.onSuccess = null; - - const result = this.task(); + const task = this.task; this.task = null; - return result; + return task(); }); }