summaryrefslogtreecommitdiffstats
path: root/src/verb/verb_store.rs
diff options
context:
space:
mode:
authorCanop <cano.petrole@gmail.com>2020-06-06 14:51:03 +0200
committerCanop <cano.petrole@gmail.com>2020-06-06 14:51:03 +0200
commit1cd64478226284d4266d441135041b2f710976b8 (patch)
tree672196300dc7d97d683f1b1b66938809206101dc /src/verb/verb_store.rs
parentfe80fc4f9e86f0603ecf39d3a3b7bae828905965 (diff)
a few minor refactorings and cleanings
Diffstat (limited to 'src/verb/verb_store.rs')
-rw-r--r--src/verb/verb_store.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/verb/verb_store.rs b/src/verb/verb_store.rs
index 9e9ff6e..17c81ab 100644
--- a/src/verb/verb_store.rs
+++ b/src/verb/verb_store.rs
@@ -12,6 +12,7 @@ use {
/// When the user types some keys, we select a verb
/// - if the input exactly matches a shortcut or the name
/// - if only one verb name starts with the input
+#[derive(Default)]
pub struct VerbStore {
pub verbs: Vec<Verb>,
}
@@ -24,9 +25,6 @@ pub enum PrefixSearchResult<'v, T> {
}
impl VerbStore {
- pub fn new() -> VerbStore {
- VerbStore { verbs: Vec::new() }
- }
pub fn init(&mut self, conf: &Conf) {
// we first add the verbs coming from configuration, as
// we'll search in order. This way, a user can overload a