From 39773e48d32edd76d98b7b25224db2b6d24937be Mon Sep 17 00:00:00 2001 From: gibbz00 Date: Mon, 29 May 2023 21:42:24 +0200 Subject: Remove superfluous command description pruning for keymap infobox: Exist under the wrong (possibly just outdated) assumption that command descriptions are written with their `KeyTrie` name prefixed --- helix-term/src/keymap.rs | 7 ------- 1 file changed, 7 deletions(-) (limited to 'helix-term') diff --git a/helix-term/src/keymap.rs b/helix-term/src/keymap.rs index 79d6b46a..f5626ee8 100644 --- a/helix-term/src/keymap.rs +++ b/helix-term/src/keymap.rs @@ -102,13 +102,6 @@ impl KeyTrieNode { .position(|&k| k == *keys.iter().next().unwrap()) .unwrap() }); - let prefix = format!("{} ", self.name()); - if body.iter().all(|(desc, _)| desc.starts_with(&prefix)) { - body = body - .into_iter() - .map(|(desc, keys)| (desc.strip_prefix(&prefix).unwrap(), keys)) - .collect(); - } Info::from_keymap(self.name(), body) } } -- cgit v1.2.3-70-g09d2