Skip to content

Commit

Permalink
0.8
Browse files Browse the repository at this point in the history
  • Loading branch information
Xiao-MoMi committed Mar 17, 2024
1 parent b7d2517 commit f781fbe
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
projectVersion = 0.7
projectVersion = 0.8
projectGroup=net.momirealms

#systemProp.socks.proxyHost=127.0.0.1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ public boolean canInteract(Player player, Location location) {

private boolean isIslandMember(Player player, Location location) {
return Optional.ofNullable(SkyBlockAPI.getIslandManager().getIslandAtLocation(location))
.map(island -> island.getRole(player) != IslandRole.VISITOR)
.map(island -> Optional.ofNullable(island.getRole(player))
.map(islandRole -> islandRole != IslandRole.VISITOR)
.orElse(false)
)
.orElse(true);
}
}

0 comments on commit f781fbe

Please sign in to comment.