mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-11-21 18:25:12 +01:00
Merge pull request #2495 from BentoBoxWorld/develop
Release 2.5.3 Bug Fix
This commit is contained in:
commit
c503ae6134
@ -150,7 +150,7 @@ public class IslandTeamCommand extends CompositeCommand {
|
||||
if (handler.objectExists(invitee.toString())) {
|
||||
@Nullable
|
||||
TeamInvite invite = getInvite(invitee);
|
||||
valid = getIslands().getIslandById(invite.getUniqueId()).map(island -> island.isOwned() // Still owned by someone
|
||||
valid = getIslands().getIslandById(invite.getIslandID()).map(island -> island.isOwned() // Still owned by someone
|
||||
&& !island.isDeleted() // Not deleted
|
||||
&& island.getMemberSet().contains(invite.getInviter()) // the inviter is still a member of the island
|
||||
).orElse(false);
|
||||
|
@ -301,7 +301,7 @@ public class IslandCache {
|
||||
* @since 2.4.0
|
||||
*/
|
||||
public Island loadIsland(String uniqueId) {
|
||||
return handler.loadObject(uniqueId);
|
||||
return handler.objectExists(uniqueId) ? handler.loadObject(uniqueId) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user