Skip to content

Commit

Permalink
Fix issue where logs were buggy after returning from subprocess
Browse files Browse the repository at this point in the history
Turns out that upon switching to a subprocess we were cancelling ALL
periodic tasks, which includes re-rendering the main view ever 30ms.
This completely broke our log rendering and meant that it only updated
when an event occurred
  • Loading branch information
jesseduffield committed May 26, 2024
1 parent 8a0fcf9 commit 630ea7d
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions pkg/gui/gui.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,11 +176,9 @@ func (gui *Gui) goEvery(interval time.Duration, function func() error) {
ticker := time.NewTicker(interval)
defer ticker.Stop()
for range ticker.C {
if gui.PauseBackgroundThreads {
return
if !gui.PauseBackgroundThreads {
_ = function()
}

_ = function()
}
}()
}
Expand Down

0 comments on commit 630ea7d

Please sign in to comment.