Skip to content
This repository was archived by the owner on Jun 7, 2022. It is now read-only.

Commit f6d1819

Browse files
einrobinGiantTreeLP
authored andcommitted
Fix ClassCastException when using Vault "getPlayerGroups(String, String)"
1 parent 063f0bd commit f6d1819

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cloudnet-api/cloudnet-api-bridge/src/main/java/de/dytanic/cloudnet/bridge/vault/VaultPermissionImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ public boolean playerRemoveGroup(String world, String player, String group) {
128128
@Override
129129
public String[] getPlayerGroups(String world, String player) {
130130
PermissionEntity permissionEntity = getPlayer(player).getPermissionEntity();
131-
return (String[]) permissionEntity.getGroups().stream().map(GroupEntityData::getGroup).toArray();
131+
return permissionEntity.getGroups().stream().map(GroupEntityData::getGroup).toArray(String[]::new);
132132
}
133133

134134
@Override

0 commit comments

Comments
 (0)