mirror of
https://github.com/essentials/Essentials.git
synced 2025-07-31 11:50:35 +02:00
New permission: essentials.repair.armor
If a player has this permission '/repair all' will also repair equipped armor.
This commit is contained in:
@@ -31,7 +31,8 @@ public class Commandbanip extends EssentialsCommand
|
||||
else
|
||||
{
|
||||
final String ipAddress = u.getLastLoginAddress();
|
||||
if (ipAddress.length() == 0) {
|
||||
if (ipAddress.length() == 0)
|
||||
{
|
||||
throw new Exception(Util.i18n("playerNotFound"));
|
||||
}
|
||||
ess.getServer().banIP(u.getLastLoginAddress());
|
||||
|
@@ -50,7 +50,9 @@ public class Commandrepair extends EssentialsCommand
|
||||
final List<String> repaired = new ArrayList<String>();
|
||||
repairItems(user.getInventory().getContents(), user, repaired);
|
||||
|
||||
repairItems(user.getInventory().getArmorContents(), user, repaired);
|
||||
if (user.isAuthorized("essentials.repair.armor")) {
|
||||
repairItems(user.getInventory().getArmorContents(), user, repaired);
|
||||
}
|
||||
|
||||
if (repaired.isEmpty())
|
||||
{
|
||||
|
Reference in New Issue
Block a user