(duration time.Duration)
| 398 | } |
| 399 | |
| 400 | func float64Ptr(value float64) *float64 { |
| 401 | return &value |
| 402 | } |
| 403 | |
| 404 | func formatDurationSeconds(duration time.Duration) string { |
| 405 | text := strconv.FormatFloat(duration.Seconds(), 'f', -1, 64) |
| 406 | if !strings.ContainsAny(text, ".eE") { |
| 407 | text += ".0" |
| 408 | } |
| 409 | return text |