mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-10-06 11:38:13 +02:00
Sanity Check.
This commit is contained in:
parent
e89f1d8a03
commit
4015351c85
@ -28,7 +28,7 @@ public class Commandrepair extends EssentialsCommand
|
||||
if (args[0].equalsIgnoreCase("hand"))
|
||||
{
|
||||
final ItemStack item = user.getItemInHand();
|
||||
if (item == null)
|
||||
if (item == null || item.getType().isBlock() || item.getDurability() == 0)
|
||||
{
|
||||
throw new Exception(_("repairInvalidType"));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user