Skip to content

Commit

Permalink
remove debugging in LangNumberFormat
Browse files Browse the repository at this point in the history
  • Loading branch information
TropheusJ committed Mar 26, 2024
1 parent efde1cf commit d278ca9
Showing 1 changed file with 3 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import java.util.Locale;

import net.minecraft.client.Minecraft;
import net.minecraft.client.resources.language.LanguageInfo;
import net.minecraft.util.Mth;

public class LangNumberFormat {
Expand All @@ -17,17 +16,10 @@ public NumberFormat get() {
}

public void update() {
LanguageInfo lang = Minecraft.getInstance()
format = NumberFormat.getInstance(Minecraft.getInstance()
.getLanguageManager()
.getSelected();
Locale locale = lang.getJavaLocale();

// fabric: clear error if this is somehow null.
if (locale == null) {
throw new IllegalStateException("LanguageInfo's javaLocale is null! info: " + lang);
}

format = NumberFormat.getInstance(locale);
.getSelected()
.getJavaLocale());
format.setMaximumFractionDigits(2);
format.setMinimumFractionDigits(0);
format.setGroupingUsed(true);
Expand Down

0 comments on commit d278ca9

Please sign in to comment.