Fix player not being expelled from visitors if in team (#1670)

* Fix player not being expelled from visitors if in team

* Error on arguments
This commit is contained in:
Alberto 2021-02-03 02:16:42 +01:00 committed by GitHub
parent bb7ed2b85c
commit 455e662d22
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -119,7 +119,7 @@ public class IslandExpelCommand extends CompositeCommand {
target.sendMessage("commands.island.expel.player-expelled-you", TextVariables.NAME, user.getName());
island.getWorld().playSound(target.getLocation(), Sound.ENTITY_GENERIC_EXPLODE, 1F, 1F);
if (getIslands().hasIsland(getWorld(), target)) {
if (getIslands().hasIsland(getWorld(), target) || getIslands().inTeam(getWorld(), target.getUniqueId())) {
// Success
user.sendMessage(SUCCESS, TextVariables.NAME, target.getName());
// Teleport home