We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9d3af8d commit 8f85cd7Copy full SHA for 8f85cd7
core/Progress.fs
@@ -50,12 +50,10 @@ module internal WindowsProgress =
50
let title = System.Console.Title
51
52
let fmtTs (ts:System.TimeSpan) =
53
- let format_string = function
54
- | _ when ts.TotalHours >= 1.0 -> "h'h'\ mm'm'\ ss's'"
55
- | _ when ts.TotalMinutes >= 1.0 -> "mm'm'\ ss's'"
56
- | _ -> "'ss's'"
57
- in
58
- format_string ts |> ts.ToString
+ (if ts.TotalHours >= 1.0 then "h'h'\ mm'm'\ ss's'"
+ else if ts.TotalMinutes >= 1.0 then "mm'm'\ ss's'"
+ else "'0m 'ss's'")
+ |> ts.ToString
59
60
// try to change a title to ensure we will not fail later
61
System.Console.Title <- title
0 commit comments