mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-06-24 13:54:51 +02:00
Only check island distances for known worlds.
BentoBox would refuse to start if islands from worlds unknown to the server were in the database. e.g. a CaveBlock island where the CaveBlock addon had been removed.
This commit is contained in:
parent
e9370b9a05
commit
a6d1acf59d
|
@ -1060,7 +1060,9 @@ public class IslandsManager {
|
|||
// Add to quarantine cache
|
||||
quarantineCache.computeIfAbsent(island.getOwner(), k -> new ArrayList<>()).add(island);
|
||||
} // Check island distance and if incorrect stop BentoBox
|
||||
else if (island.getRange() != plugin.getIWM().getIslandDistance(island.getWorld())) {
|
||||
else if (island.getWorld() != null
|
||||
&& plugin.getIWM().inWorld(island.getWorld())
|
||||
&& island.getRange() != plugin.getIWM().getIslandDistance(island.getWorld())) {
|
||||
throw new IOException("Island distance mismatch!\n"
|
||||
+ "World '" + island.getWorld().getName() + "' distance " + plugin.getIWM().getIslandDistance(island.getWorld()) + " != island range " + island.getRange() + "!\n"
|
||||
+ "Island ID in database is " + island.getUniqueId() + ".\n"
|
||||
|
|
Loading…
Reference in New Issue
Block a user