mirror of
https://github.com/darksaid98/Carbon.git
synced 2026-12-03 14:38:51 +00:00
fix
This commit is contained in:
1 parent
45369aa261
commit
b360680abb
1 file changed
+3
-2
@@ -27,6 +27,7 @@ import cloud.commandframework.exceptions.InvalidSyntaxException;
|
|||||||
import cloud.commandframework.exceptions.NoPermissionException;
|
import cloud.commandframework.exceptions.NoPermissionException;
|
||||||
import cloud.commandframework.execution.FilteringCommandSuggestionProcessor;
|
import cloud.commandframework.execution.FilteringCommandSuggestionProcessor;
|
||||||
import com.google.inject.Inject;
|
import com.google.inject.Inject;
|
||||||
|
import com.google.inject.Provider;
|
||||||
import java.io.PrintWriter;
|
import java.io.PrintWriter;
|
||||||
import java.io.StringWriter;
|
import java.io.StringWriter;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
@@ -56,7 +57,7 @@ public final class CloudUtils {
|
|||||||
private static final Pattern SPECIAL_CHARACTERS_PATTERN = Pattern.compile("[^\\s\\w\\-]");
|
private static final Pattern SPECIAL_CHARACTERS_PATTERN = Pattern.compile("[^\\s\\w\\-]");
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
private static Set<CarbonCommand> commands;
|
private static Provider<Set<CarbonCommand>> commands;
|
||||||
|
|
||||||
private CloudUtils() {
|
private CloudUtils() {
|
||||||
|
|
||||||
@@ -65,7 +66,7 @@ public final class CloudUtils {
|
|||||||
public static Map<Key, CommandSettings> defaultCommandSettings() {
|
public static Map<Key, CommandSettings> defaultCommandSettings() {
|
||||||
final Map<Key, CommandSettings> settings = new HashMap<>();
|
final Map<Key, CommandSettings> settings = new HashMap<>();
|
||||||
|
|
||||||
for (final var command : commands) {
|
for (final var command : commands.get()) {
|
||||||
settings.put(command.key(), command.commandSettings());
|
settings.put(command.key(), command.commandSettings());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user