From 90206c58c326c6ed7196450fcc9cee02f1711550 Mon Sep 17 00:00:00 2001 From: broccolai Date: Thu, 29 Apr 2021 13:37:16 +0100 Subject: [PATCH] Fix commands on Spigot --- .../main/java/broccolai/tickets/bukkit/BukkitPlatform.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plugin/bukkit/src/main/java/broccolai/tickets/bukkit/BukkitPlatform.java b/plugin/bukkit/src/main/java/broccolai/tickets/bukkit/BukkitPlatform.java index 8ba39e5e..75e43bc7 100644 --- a/plugin/bukkit/src/main/java/broccolai/tickets/bukkit/BukkitPlatform.java +++ b/plugin/bukkit/src/main/java/broccolai/tickets/bukkit/BukkitPlatform.java @@ -12,6 +12,7 @@ import broccolai.tickets.core.inject.platform.PluginPlatform; import broccolai.tickets.core.utilities.ArrayHelper; import cloud.commandframework.CommandManager; +import cloud.commandframework.bukkit.CloudBukkitCapabilities; import cloud.commandframework.exceptions.InvalidCommandSenderException; import cloud.commandframework.execution.AsynchronousCommandExecutionCoordinator; import cloud.commandframework.minecraft.extras.MinecraftExceptionHandler; @@ -98,7 +99,9 @@ private CommandManager commandManager( } ); - cloudManager.registerAsynchronousCompletions(); + if (cloudManager.queryCapability(CloudBukkitCapabilities.ASYNCHRONOUS_COMPLETION)) { + cloudManager.registerAsynchronousCompletions(); + } new MinecraftExceptionHandler<@NonNull OnlineSoul>() .withDefaultHandlers()