Vault

Vault

7M Downloads

Permission.has() can't be used with a player name but without a world

literalplus opened this issue ยท 5 comments

commented

The class Permission has no has(String player,String permission) method, but contains has(World world, String player, String permission).
I would like to check for a player's permission by their name without a World in one of my plugins, but currently this is not possible.
Obviously, I can easily workaround the issue, but I think it would be helpful if requested method was implemented.

commented

Then use has(null, player, permission) :)

commented

Thanks, please add this to javadoc :)

commented

already there

commented

@xxyy - as @criztovyl mentioned, it's already doced here: https://github.com/MilkBowl/Vault/blob/master/src/net/milkbowl/vault/permission/Permission.java#L56

If you're using generic permissions checks you should probably not be using Vault anyway.

commented

@Sleaker I planned on using it to check for a permission by player name which is currently not possible as easy when using bukkit permissions.