From b6712ff7ddafbca376d93a9b47c6117064f2e41b Mon Sep 17 00:00:00 2001 From: classicalliu Date: Thu, 8 Aug 2019 14:43:57 +0800 Subject: [PATCH] fix: waitForDrained --- packages/neuron-wallet/src/services/sync/queue.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/neuron-wallet/src/services/sync/queue.ts b/packages/neuron-wallet/src/services/sync/queue.ts index b3977c0c7a..7476263056 100644 --- a/packages/neuron-wallet/src/services/sync/queue.ts +++ b/packages/neuron-wallet/src/services/sync/queue.ts @@ -76,7 +76,7 @@ export default class Queue { public waitForDrained = async (timeout: number = 5000) => { const startAt: number = +new Date() - while (!this.inProcess) { + while (this.inProcess) { const now: number = +new Date() if (now - startAt > timeout) { return