Skip to content

Commit

Permalink
fix(spinner): fix line didn't clear properly
Browse files Browse the repository at this point in the history
  • Loading branch information
floaust committed Jun 22, 2022
1 parent 8dc2bc1 commit efba353
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions spinner_printer.go
Expand Up @@ -146,6 +146,7 @@ func (s SpinnerPrinter) Start(text ...interface{}) (*SpinnerPrinter, error) {
if s.ShowTimer {
timer = " (" + time.Since(s.startedAt).Round(s.TimerRoundingFactor).String() + ")"
}
fClearLine(s.Writer)
Fprinto(s.Writer, s.Style.Sprint(seq)+" "+s.MessageStyle.Sprint(s.Text)+s.TimerStyle.Sprint(timer))
s.currentSequence = seq
time.Sleep(s.Delay)
Expand Down

0 comments on commit efba353

Please sign in to comment.