diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java index 86f7cf5539..212ba7dbe0 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -551,13 +551,21 @@ public final class CraftServer implements Server { return true; } - public Map getCommandAliases() { + public Map getCommandAliases() { ConfigurationNode node = configuration.getNode("aliases"); - Map result = new HashMap(); + Map result = new HashMap(); if (node != null) { for (String key : node.getKeys()) { - result.put(key, node.getString(key)); + List commands = new ArrayList(); + + if (node.getProperty(key) instanceof List) { + commands = node.getStringList(key, null); + } else { + commands.add(node.getString(key)); + } + + result.put(key, commands.toArray(new String[0])); } }