Fix config string format in MobTypes.java

Replaced concatenation with String.format for clarity and consistency. This change ensures that the configuration strings are constructed correctly, preventing potential runtime errors.
This commit is contained in:
2024-10-18 23:51:54 +02:00
parent f36bc6fc7f
commit e8b926ab41
@@ -74,7 +74,7 @@ public class MobTypes extends AbstractConfig {
config.getConfigurationSection(prefix + key + ".modifiers").getKeys(false).forEach(modifier -> {
log.info("{}{}.modifiers.{}", prefix, key, modifier);
log.info("5 {}", modifier);
String attribute = config.getString(prefix + key + ".modifiers." + modifier, "attribute", null);
String attribute = config.getString(String.format("%s%s.modifiers.%s.", prefix, key, modifier), "attribute", null);
log.info("6");
if (attribute == null) {
log.info("RETURN (7)");