Whoops ;D

This commit is contained in:
benwoo1110 2020-12-26 20:37:47 +08:00
parent 8c18caf30b
commit 90937d6322

View File

@ -42,8 +42,7 @@ public class GeneratorCommand extends MultiverseCommand {
public static void showAvailableGenerator(@NotNull CommandSender sender) {
List<String> generators = Arrays.stream(Bukkit.getServer().getPluginManager().getPlugins())
.filter(Plugin::isEnabled)
//TODO ACF: Think what if they do not have a world named 'world'
.filter(plugin -> plugin.getDefaultWorldGenerator("idiot", "") != null)
.filter(plugin -> plugin.getDefaultWorldGenerator("world", "") != null)
.map(plugin -> plugin.getDescription().getName())
.collect(Collectors.toList());