mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-11-27 01:40:48 +08:00
Fix format parsing in /unlimited
This commit is contained in:
parent
0cd47639c2
commit
ac0ba8890f
@ -2,6 +2,7 @@ package com.earth2me.essentials.commands;
|
||||
|
||||
import com.earth2me.essentials.User;
|
||||
import com.earth2me.essentials.craftbukkit.Inventories;
|
||||
import com.earth2me.essentials.utils.AdventureUtil;
|
||||
import net.ess3.api.TranslatableException;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.Server;
|
||||
@ -29,7 +30,7 @@ public class Commandunlimited extends EssentialsCommand {
|
||||
}
|
||||
|
||||
if (args[0].equalsIgnoreCase("list")) {
|
||||
user.sendMessage(getList(user, target));
|
||||
user.sendComponent(AdventureUtil.miniMessage().deserialize(getList(user, target)));
|
||||
} else if (args[0].equalsIgnoreCase("clear")) {
|
||||
for (final Material m : new HashSet<>(target.getUnlimited())) {
|
||||
if (m == null) {
|
||||
@ -56,7 +57,7 @@ public class Commandunlimited extends EssentialsCommand {
|
||||
}
|
||||
joiner.add(material.toString().toLowerCase(Locale.ENGLISH).replace("_", ""));
|
||||
}
|
||||
output.append(joiner.toString());
|
||||
output.append(joiner);
|
||||
|
||||
return output.toString();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user