mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2025-02-28 10:12:24 +01:00
NPE avoid.
This commit is contained in:
parent
ec60991aeb
commit
24b7d26fbe
@ -75,7 +75,7 @@ public class AdminTeamDisbandCommand extends CompositeCommand {
|
||||
island = islands.values().iterator().next();
|
||||
}
|
||||
// Check that the target owns the island
|
||||
if (!island.getOwner().equals(targetUUID)) {
|
||||
if (island.getOwner() == null || !island.getOwner().equals(targetUUID)) {
|
||||
user.sendMessage("general.errors.player-is-not-owner", TextVariables.NAME, args.get(0));
|
||||
return false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user