Skip to content

Commit a760bbe

Browse files
committed
fix: ui event delays
1 parent cdc93a1 commit a760bbe

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

internal/cli/run.go

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -511,10 +511,10 @@ func runUI(cfg *ui.Config, cr common.Commander) error {
511511
lastEventTime := time.Now()
512512
for event := range ch {
513513
switch e := event.(type) {
514-
case command.EventStart:
514+
case command.EventStart, command.EventListResources:
515515
p.Send(e)
516516

517-
case command.EventEnd, command.EventConfigure:
517+
case command.EventEnd, command.EventConfigure, command.EventOpenResource:
518518
if time.Since(lastEventTime) < *cfg.UI.MinimumDelay {
519519
// Add a delay if the command ran faster than MinimumDelay.
520520
// This prevents the status from flickering in the UI.
@@ -523,9 +523,6 @@ func runUI(cfg *ui.Config, cr common.Commander) error {
523523

524524
p.Send(e)
525525

526-
case command.EventOpenResource, command.EventListResources:
527-
p.Send(e)
528-
529526
case command.EventCancel:
530527
continue
531528
}

0 commit comments

Comments
 (0)