mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-11-02 17:09:58 +01:00
Fixing repair to not repair items with datavalues, unless they actually have a durability.
This commit is contained in:
parent
492c4e8521
commit
3ff1f4adbb
@ -80,7 +80,7 @@ public class Commandrepair extends EssentialsCommand
|
||||
private void repairItem(final ItemStack item) throws Exception
|
||||
{
|
||||
final Material material = Material.getMaterial(item.getTypeId());
|
||||
if (material.isBlock() || material.getMaxDurability() < 0)
|
||||
if (material.isBlock() || material.getMaxDurability() < 1)
|
||||
{
|
||||
throw new Exception(_("repairInvalidType"));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user