mirror of
https://github.com/tulir/gomuks.git
synced 2025-04-19 18:13:41 -05:00
Remove temporary progress bar logs
This commit is contained in:
parent
507aa3c61c
commit
97d2e77a8e
1 changed files with 1 additions and 4 deletions
|
@ -60,15 +60,12 @@ func (s *GomuksSyncer) ProcessResponse(res *mautrix.RespSync, since string) (err
|
||||||
debug.Print("Received sync response")
|
debug.Print("Received sync response")
|
||||||
s.Progress.SetMessage("Processing sync response")
|
s.Progress.SetMessage("Processing sync response")
|
||||||
steps := len(res.Rooms.Join) + len(res.Rooms.Invite) + len(res.Rooms.Leave)
|
steps := len(res.Rooms.Join) + len(res.Rooms.Invite) + len(res.Rooms.Leave)
|
||||||
visualSteps := steps + 2 + len(s.globalListeners)
|
s.Progress.SetSteps(steps + 2 + len(s.globalListeners))
|
||||||
debug.Printf("[SYNC] Creating a progress bar with %s steps (%s rooms, %s global listeners)", visualSteps, steps, len(s.globalListeners))
|
|
||||||
s.Progress.SetSteps(visualSteps)
|
|
||||||
|
|
||||||
wait := &sync.WaitGroup{}
|
wait := &sync.WaitGroup{}
|
||||||
callback := func() {
|
callback := func() {
|
||||||
wait.Done()
|
wait.Done()
|
||||||
s.Progress.Step()
|
s.Progress.Step()
|
||||||
debug.Print("[SYNC] Stepping progress bar")
|
|
||||||
}
|
}
|
||||||
wait.Add(len(s.globalListeners))
|
wait.Add(len(s.globalListeners))
|
||||||
s.notifyGlobalListeners(res, since, callback)
|
s.notifyGlobalListeners(res, since, callback)
|
||||||
|
|
Loading…
Add table
Reference in a new issue