diff options
Diffstat (limited to 'paper-api-generator')
-rw-r--r-- | paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalNames.java | 5 | ||||
-rw-r--r-- | paper-api-generator/src/main/java/io/papermc/generator/utils/Formatting.java | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalNames.java b/paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalNames.java index 2ad5e0ac06..1bd6342f61 100644 --- a/paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalNames.java +++ b/paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalNames.java @@ -120,6 +120,7 @@ import org.bukkit.entity.ZombieVillager; import java.lang.reflect.Constructor; import java.util.HashMap; import java.util.HashSet; +import java.util.Locale; import java.util.Map; import java.util.Set; @@ -282,8 +283,8 @@ public class MobGoalNames { name = sb.toString(); name = name.replaceFirst("_", ""); - if (flag && !deobfuscationMap.containsKey(name.toLowerCase()) && !ignored.contains(name)) { - System.out.println("need to map " + original + " (" + name.toLowerCase() + ")"); + if (flag && !deobfuscationMap.containsKey(name.toLowerCase(Locale.ROOT)) && !ignored.contains(name)) { + System.out.println("need to map " + original + " (" + name.toLowerCase(Locale.ROOT) + ")"); } // did we rename this key? diff --git a/paper-api-generator/src/main/java/io/papermc/generator/utils/Formatting.java b/paper-api-generator/src/main/java/io/papermc/generator/utils/Formatting.java index a6c88a8a14..9d938f8cb7 100644 --- a/paper-api-generator/src/main/java/io/papermc/generator/utils/Formatting.java +++ b/paper-api-generator/src/main/java/io/papermc/generator/utils/Formatting.java @@ -12,7 +12,7 @@ public final class Formatting { private static final Pattern ILLEGAL_FIELD_CHARACTERS = Pattern.compile("[.-/]"); public static String formatKeyAsField(String path) { - return ILLEGAL_FIELD_CHARACTERS.matcher(path.toUpperCase(Locale.ENGLISH)).replaceAll("_"); + return ILLEGAL_FIELD_CHARACTERS.matcher(path.toUpperCase(Locale.ROOT)).replaceAll("_"); } public static Comparator<String> ALPHABETIC_KEY_ORDER = alphabeticKeyOrder(path -> path); |