Fix latency issue

This commit is contained in:
Martin Pander
2026-09-11 13:17:04 +02:00
parent 6b1418fc71
commit 6fbe575471
4 changed files with 26 additions and 17 deletions

View File

@@ -93,7 +93,7 @@ func min(a, b int) int {
}
func (p *ReportPage) Init() tea.Cmd {
return tea.Batch(p.getTasks(), doTick())
return p.getTasks()
}
func (p *ReportPage) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
@@ -104,7 +104,6 @@ func (p *ReportPage) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
// case BackMsg:
case tickMsg:
cmds = append(cmds, p.getTasks())
cmds = append(cmds, doTick())
return p, tea.Batch(cmds...)
case taskMsg:
p.tasks = taskwarrior.Tasks(msg)