mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-12-29 04:27:46 +01:00
Fixed NPE in IslandManager on startup
This commit is contained in:
parent
f59ea87e74
commit
9b478fbef6
@ -155,7 +155,11 @@ public class IslandWorldManager {
|
||||
* @return world settings, or null if world is unknown
|
||||
*/
|
||||
public WorldSettings getWorldSettings(World world) {
|
||||
return gameModes.get(Util.getWorld(world)).getWorldSettings();
|
||||
if (gameModes.containsKey(Util.getWorld(world))) {
|
||||
return gameModes.get(Util.getWorld(world)).getWorldSettings();
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user