mirror of https://github.com/helix-editor/helix
Avoid trailing `s` in message when only 1 file is opened (#5189)
parent
b1ca7ddf89
commit
24c3b00d10
|
@ -227,7 +227,11 @@ impl Application {
|
|||
doc.set_selection(view_id, pos);
|
||||
}
|
||||
}
|
||||
editor.set_status(format!("Loaded {} files.", nr_of_files));
|
||||
editor.set_status(format!(
|
||||
"Loaded {} file{}.",
|
||||
nr_of_files,
|
||||
if nr_of_files == 1 { "" } else { "s" } // avoid "Loaded 1 files." grammo
|
||||
));
|
||||
// align the view to center after all files are loaded,
|
||||
// does not affect views without pos since it is at the top
|
||||
let (view, doc) = current!(editor);
|
||||
|
|
Loading…
Reference in New Issue