Skip to content

Commit

Permalink
fix: waitForDrained
Browse files Browse the repository at this point in the history
  • Loading branch information
classicalliu committed Aug 8, 2019
1 parent abdc01f commit b6712ff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/neuron-wallet/src/services/sync/queue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit b6712ff

Please sign in to comment.