Skip to content

Commit

Permalink
Don't interpolate config comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Nightenom committed Sep 15, 2024
1 parent b140c7b commit 6b45a2c
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
import net.neoforged.neoforge.common.ModConfigSpec.RestartType;
import net.neoforged.neoforge.common.util.LogicalSidedProvider;
import org.jetbrains.annotations.Nullable;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
Expand Down Expand Up @@ -93,7 +94,8 @@ private Builder buildBase(final String key, @Nullable final String defaultDesc)

private static String translate(final String key, final Object... args)
{
return LanguageHandler.translateKey(key).formatted(args);
final String translated = LanguageHandler.translateKey(key);
return args.length == 0 ? translated : translated.formatted(args);
}

protected AbstractConfiguration requiresWorldRestart()
Expand Down

0 comments on commit 6b45a2c

Please sign in to comment.