Fix latency issue
This commit is contained in:
@@ -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)
|
||||
|
||||
Reference in New Issue
Block a user