mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-12-30 21:17:38 +01:00
Only show ban reason in the in-game display, not full banFormat.
This commit is contained in:
parent
f8cf3be87f
commit
d74952927a
@ -58,17 +58,17 @@ public class Commandban extends EssentialsCommand
|
||||
String banReason;
|
||||
if (args.length > 1)
|
||||
{
|
||||
banReason = _("banFormat", Util.replaceFormat(getFinalArg(args, 1).replace("\\n", "\n").replace("|", "\n")), senderName);
|
||||
banReason = Util.replaceFormat(getFinalArg(args, 1).replace("\\n", "\n").replace("|", "\n"));
|
||||
}
|
||||
else
|
||||
{
|
||||
banReason = _("banFormat", _("defaultBanReason"), senderName);
|
||||
banReason = _("defaultBanReason");
|
||||
}
|
||||
|
||||
user.setBanReason(banReason);
|
||||
user.setBanReason(_("banFormat", banReason, senderName));
|
||||
user.setBanned(true);
|
||||
user.setBanTimeout(0);
|
||||
user.kickPlayer(banReason);
|
||||
user.kickPlayer(_("banFormat", banReason, senderName));
|
||||
|
||||
server.getLogger().log(Level.INFO, _("playerBanned", senderName, user.getName(), banReason));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user