mirror of
https://github.com/helix-editor/helix
synced 2024-11-10 10:34:45 +01:00
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
This commit is contained in:
parent
d20c1632a7
commit
39773e48d3
@ -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)
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user