Skip to content

Commit

Permalink
Merge pull request #3 from Chyroc/fix/remove-Duration.Round-to-compat…
Browse files Browse the repository at this point in the history
…ible-with-version-less-than-go1.9

fix remove Duration.Round to compatible with version less than go1.9
  • Loading branch information
schollz authored Oct 31, 2017
2 parents 6ed0369 + 0d2642a commit 98649a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion progressbar.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ func (p *ProgressBar) Show() error {
strings.Repeat(p.symbolFinished, p.currentSaucerSize),
strings.Repeat(p.symbolLeft, p.size-p.currentSaucerSize),
p.rightBookend,
time.Since(p.startTime).Round(time.Second).String(),
(time.Duration(time.Since(p.startTime).Seconds()) * time.Second).String(),
(time.Duration(secondsLeft) * time.Second).String(),
)

Expand Down

0 comments on commit 98649a7

Please sign in to comment.