mirror of
https://github.com/ChestShop-authors/ChestShop-3.git
synced 2024-09-28 22:47:46 +02:00
Cancel before sending message so that access is denied in case of error
This commit is contained in:
parent
493784c2dd
commit
9cbf33f68f
@ -66,8 +66,8 @@ public class PlayerInteract implements Listener {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!Security.canAccess(player, block)) {
|
if (!Security.canAccess(player, block)) {
|
||||||
Messages.ACCESS_DENIED.sendWithPrefix(player);
|
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
|
Messages.ACCESS_DENIED.sendWithPrefix(player);
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user