Fixed easy style issues.

This commit is contained in:
delbertina 2017-11-26 00:55:05 -06:00
parent fcda6c3b3b
commit 6f7af90488
3 changed files with 3 additions and 4 deletions

View File

@ -81,7 +81,7 @@ public class EssentialsPlayerListener implements Listener {
if (user.isMuted()) { if (user.isMuted()) {
event.setCancelled(true); event.setCancelled(true);
if (user.getMuteReason ().equals ("")) { if (user.getMuteReason().equals ("")) {
user.sendMessage(tl("voiceSilenced")); user.sendMessage(tl("voiceSilenced"));
} }
else { else {

View File

@ -525,7 +525,7 @@ public abstract class UserData extends PlayerExtension implements IConf {
} }
} }
public void setMuteReason (String reason) { public void setMuteReason(String reason) {
if (reason.equals("")) { if (reason.equals("")) {
config.removeProperty ("muteReason"); config.removeProperty ("muteReason");
muteReason = null; muteReason = null;

View File

@ -82,8 +82,7 @@ public class Commandmute extends EssentialsCommand {
if (user.getMuteReason ().equals ("")) { if (user.getMuteReason ().equals ("")) {
sender.sendMessage(tl("mutedPlayerFor", user.getDisplayName(), muteTime)); sender.sendMessage(tl("mutedPlayerFor", user.getDisplayName(), muteTime));
user.sendMessage(tl("playerMutedFor", muteTime)); user.sendMessage(tl("playerMutedFor", muteTime));
} } else {
else {
sender.sendMessage(tl("mutedPlayerFor", user.getDisplayName(), muteTime) + tl("muteFormat",user.getMuteReason())); sender.sendMessage(tl("mutedPlayerFor", user.getDisplayName(), muteTime) + tl("muteFormat",user.getMuteReason()));
user.sendMessage(tl("playerMutedFor", muteTime) + tl("muteFormat",user.getMuteReason())); user.sendMessage(tl("playerMutedFor", muteTime) + tl("muteFormat",user.getMuteReason()));
} }