mirror of
https://github.com/nushell/nushell.git
synced 2025-06-30 22:50:14 +02:00
update miette and switch to GenericErrors (#5222)
This commit is contained in:
@ -151,11 +151,11 @@ fn string_to_duration(s: &str, span: Span) -> Result<i64, ShellError> {
|
||||
}
|
||||
}
|
||||
|
||||
Err(ShellError::CantConvertWithHelp(
|
||||
Err(ShellError::CantConvert(
|
||||
"duration".to_string(),
|
||||
"string".to_string(),
|
||||
span,
|
||||
"supported units are ns, us, ms, sec, min, hr, day, and wk".to_string(),
|
||||
Some("supported units are ns, us, ms, sec, min, hr, day, and wk".to_string()),
|
||||
))
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user