}
public static StringArgumentType string() {
- return StringArgumentType.greedyString();
+ return StringArgumentType.string();
}
public static BoolArgumentType bool() {
return getArgumentValueOrDefault(context, name, BoolArgumentType::getBool, () -> false);
}
-
- public static <T> T getArgumentValueOrDefault(CommandContext<CommandSource> context,
- String name,
- ArgumentFetcher<T> getValue,
- Supplier<T> defaultValue) throws CommandSyntaxException {
+ private static <T> T getArgumentValueOrDefault(CommandContext<CommandSource> context,
+ String name,
+ ArgumentFetcher<T> getValue,
+ Supplier<T> defaultValue) throws CommandSyntaxException {
try {
return getValue.get(context, name);
} catch (IllegalArgumentException exception) {