Uniformization of how permission check is handled between pandalib-(.*-)players, Paper/Bungee and pandalib-permissions.
When an *OnlinePlayer class ask for permission, it always ask for Paper/Bungee API. The pandalib-permissions system will be called by Paper/Bungee only if it used and integrated into Paper/Bungee using the appropriate modules. This commit reduces inter-dependencies between pandalib-(.*-)permissions modules and pandalib-(.*-)players (except pandalib-players-permissible that has to depends on pandalib-permissions)
This commit is contained in:
@@ -63,6 +63,21 @@ public interface BungeeOnlinePlayer extends BungeeOffPlayer, StandaloneOnlinePla
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Permissions and groups
|
||||
*/
|
||||
|
||||
/**
|
||||
* Tells if this online player has the specified permission.
|
||||
*/
|
||||
default boolean hasPermission(String permission) {
|
||||
return getBungeeProxiedPlayer().hasPermission(permission);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Sending packet and stuff to player
|
||||
|
Reference in New Issue
Block a user