From 9f75f1aad30a71d03570e03f71c6c2fd02ec49ca Mon Sep 17 00:00:00 2001 From: AdamQpzm Date: Mon, 4 Jan 2016 21:32:19 +0000 Subject: [PATCH] Add bypass permission to nick command This should allow users of wildcard permissions to be able to change their nicks as intended, without any changes to their current setup. --- .../src/com/earth2me/essentials/commands/Commandnick.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandnick.java b/Essentials/src/com/earth2me/essentials/commands/Commandnick.java index 96ada76b0..ab1cd4833 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandnick.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandnick.java @@ -79,7 +79,7 @@ public class Commandnick extends EssentialsLoopCommand { throw new Exception(tl("nickTooLong")); } else if (FormatUtil.stripFormat(newNick).length() < 1) { throw new Exception(tl("nickNamesAlpha")); - } else if (user != null && (user.isAuthorized("essentials.nick.changecolors")) && !FormatUtil.stripFormat(newNick).equals(user.getName())) { + } else if (user != null && (user.isAuthorized("essentials.nick.changecolors") && !user.isAuthorized("essentials.nick.changecolors.bypass")) && !FormatUtil.stripFormat(newNick).equals(user.getName())) { throw new Exception(tl("nickNamesOnlyColorChanges")); } return newNick;