diff --git a/src/format.rs b/src/format.rs index 7475a251..b5f411ca 100644 --- a/src/format.rs +++ b/src/format.rs @@ -3,7 +3,7 @@ use std::time::Duration; use number_prefix::NumberPrefix; -const SECOND: Duration = Duration::from_secs(1); +const MILLISECOND: Duration = Duration::from_millis(1); const MINUTE: Duration = Duration::from_secs(60); const HOUR: Duration = Duration::from_secs(60 * 60); const DAY: Duration = Duration::from_secs(24 * 60 * 60); @@ -103,7 +103,7 @@ const UNITS: &[(Duration, &str, &str)] = &[ (DAY, "day", "d"), (HOUR, "hour", "h"), (MINUTE, "minute", "m"), - (SECOND, "second", "s"), + (MILLISECOND, "millisecond", "ms"), ]; impl fmt::Display for HumanBytes {