Check permission before sending anvil messages

This commit is contained in:
TfT_02 2014-05-25 22:46:35 +02:00
parent 4bcef76fd8
commit 3c6c2837bd

View File

@ -125,10 +125,10 @@ public class BlockListener implements Listener {
McMMOPlayer mcMMOPlayer = UserManager.getPlayer(player); McMMOPlayer mcMMOPlayer = UserManager.getPlayer(player);
if (blockState.getType() == Repair.anvilMaterial) { if (blockState.getType() == Repair.anvilMaterial && SkillType.REPAIR.getPermissions(player)) {
mcMMOPlayer.getRepairManager().placedAnvilCheck(); mcMMOPlayer.getRepairManager().placedAnvilCheck();
} }
else if (blockState.getType() == Salvage.anvilMaterial) { else if (blockState.getType() == Salvage.anvilMaterial && SkillType.SALVAGE.getPermissions(player)) {
mcMMOPlayer.getSalvageManager().placedAnvilCheck(); mcMMOPlayer.getSalvageManager().placedAnvilCheck();
} }
} }