mirror of
https://github.com/nushell/nushell.git
synced 2024-11-22 08:23:24 +01:00
Fix plurals in abbrevations (#409)
This commit is contained in:
parent
19766556f3
commit
d9bedaae2f
@ -345,8 +345,16 @@ impl Value {
|
||||
)
|
||||
}
|
||||
Value::String { val, .. } => val,
|
||||
Value::List { vals: val, .. } => format!("[list {} items]", val.len()),
|
||||
Value::Record { cols, .. } => format!("{{record {} fields}}", cols.len()),
|
||||
Value::List { vals: val, .. } => format!(
|
||||
"[list {} item{}]",
|
||||
val.len(),
|
||||
if val.len() == 1 { "" } else { "s" }
|
||||
),
|
||||
Value::Record { cols, .. } => format!(
|
||||
"{{record {} field{}}}",
|
||||
cols.len(),
|
||||
if cols.len() == 1 { "" } else { "s" }
|
||||
),
|
||||
Value::Block { val, .. } => format!("<Block {}>", val),
|
||||
Value::Nothing { .. } => String::new(),
|
||||
Value::Error { error } => format!("{:?}", error),
|
||||
|
Loading…
Reference in New Issue
Block a user