Do not coop already cooped player.

Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1696
This commit is contained in:
tastybento 2021-03-06 12:25:36 -08:00
parent 92332ab755
commit f1f374c258

View File

@ -73,7 +73,7 @@ public class IslandTeamCoopCommand extends CompositeCommand {
user.sendMessage("commands.island.team.coop.cannot-coop-yourself");
return false;
}
if (getIslands().getMembers(getWorld(), user.getUniqueId()).contains(targetUUID)) {
if (getIslands().getMembers(getWorld(), user.getUniqueId(), RanksManager.COOP_RANK).contains(targetUUID)) {
user.sendMessage("commands.island.team.coop.already-has-rank");
return false;
}