mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-23 08:46:44 +01:00
Only display help aliases when there are aliases. Fixes BUKKIT-1621
This commit is contained in:
parent
dc93da8e34
commit
22b1100001
1 changed files with 6 additions and 3 deletions
|
@ -145,7 +145,10 @@ public class SimpleHelpMap implements HelpMap {
|
|||
}
|
||||
|
||||
// Add alias sub-index
|
||||
addTopic(new IndexHelpTopic("Aliases", "Lists command aliases", null, Collections2.filter(helpTopics.values(), Predicates.instanceOf(CommandAliasHelpTopic.class))));
|
||||
Collection<HelpTopic> filteredTopics = Collections2.<HelpTopic>filter(helpTopics.values(), Predicates.instanceOf(CommandAliasHelpTopic.class));
|
||||
if (!filteredTopics.isEmpty()) {
|
||||
addTopic(new IndexHelpTopic("Aliases", "Lists command aliases", null, filteredTopics));
|
||||
}
|
||||
|
||||
// Initialize plugin-level sub-topics
|
||||
Map<String, Set<HelpTopic>> pluginIndexes = new HashMap<String, Set<HelpTopic>>();
|
||||
|
|
Loading…
Add table
Reference in a new issue