mirror of
https://github.com/rockyhawk64/CommandPanels.git
synced 2025-11-18 07:14:17 +01:00
cancel command event even with no perms
This commit is contained in:
parent
732995f2f2
commit
f5993c525a
@ -68,8 +68,11 @@ public class PanelOpenCommand implements Listener {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// No panel was found that could be opened
|
// Had panel match but no panel had permission, cancel and send no perm message
|
||||||
if(hadMatch) ctx.text.sendError(e.getPlayer(), Message.COMMAND_NO_PERMISSION);
|
if(hadMatch){
|
||||||
|
ctx.text.sendError(e.getPlayer(), Message.COMMAND_NO_PERMISSION);
|
||||||
|
e.setCancelled(true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void populateCommands() {
|
public void populateCommands() {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user