Vault

Vault

7M Downloads

Permissionsbukkit getPrimaryGroup returns null

Armarr opened this issue ยท 3 comments

commented

For a new player getPrimaryGroup(Player player) returns null with Permissionsbukkit instead of returning the default rank.
Whereas it does for GM and PEX

commented

This is still an issue. It looks like because Vault is first using getPlayerInfo(player) and returning null, whereas PermissionsBukkit already does this when you just pull the groups with getGroups(player), but properly returns 'default'. Surely there's a way to do this and still get group order?

commented

Are players always in the default group if they have no groups with PBukkit?

GM/PEX return this because they explicitly force it on their returns. not because vault handles it differently. Vault assumes the permission system will return groups properly.

The code for PEX is nearly identical (except for the API differences) to what is in PBukkit.

commented

Well players are treated like they are in the default group when they have no group, I have no idea how the backend of that works. Atm I got a workaround by changing the group name to "default" if it's null. I think PBukkit's default rank is always called default anyway so that should hopefully take care of it.