Codebase list golang-github-vbauerster-mpb / 6bb1b4f
refactoring: startTime to start Vladimir Bauer 1 year, 10 months ago
1 changed file(s) with 3 addition(s) and 3 deletion(s). Raw diff Collapse all Expand all
1616 //
1717 // `style` one of [ET_STYLE_GO|ET_STYLE_HHMMSS|ET_STYLE_HHMM|ET_STYLE_MMSS]
1818 //
19 // `startTime` start time
19 // `start` start time
2020 //
2121 // `wcc` optional WC config
22 func NewElapsed(style TimeStyle, startTime time.Time, wcc ...WC) Decorator {
22 func NewElapsed(style TimeStyle, start time.Time, wcc ...WC) Decorator {
2323 var msg string
2424 producer := chooseTimeProducer(style)
2525 fn := func(s Statistics) string {
2626 if !s.Completed {
27 msg = producer(time.Since(startTime))
27 msg = producer(time.Since(start))
2828 }
2929 return msg
3030 }