From d8c31e8efab3d4eada0dfb8dc7792510681559bf Mon Sep 17 00:00:00 2001 From: Noogear <123232885+Noogear@users.noreply.github.com> Date: Wed, 13 Nov 2024 15:05:25 +0800 Subject: [PATCH] Update MobSpawn.java --- src/main/java/dev/aurelium/auramobs/listeners/MobSpawn.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/dev/aurelium/auramobs/listeners/MobSpawn.java b/src/main/java/dev/aurelium/auramobs/listeners/MobSpawn.java index 782f7cf..3ed6013 100644 --- a/src/main/java/dev/aurelium/auramobs/listeners/MobSpawn.java +++ b/src/main/java/dev/aurelium/auramobs/listeners/MobSpawn.java @@ -84,15 +84,17 @@ private boolean passWorld(World world) { if (plugin.isWorldWhitelist()) { if (plugin.getEnabledWorlds().contains("*")) return true; for (String enabledworld : plugin.getEnabledWorlds()) { - if (world.getName().equalsIgnoreCase(enabledworld) || world.getName().startsWith(enabledworld.replace("*", ""))) + if (world.getName().equalsIgnoreCase(enabledworld) || world.getName().startsWith(enabledworld.replace("*", ""))) { return true; + } } return false; } else { if (plugin.getEnabledWorlds().contains("*")) return false; for (String enabledworld : plugin.getEnabledWorlds()) { - if (world.getName().equalsIgnoreCase(enabledworld) || world.getName().startsWith(enabledworld.replace("*", ""))) + if (world.getName().equalsIgnoreCase(enabledworld) || world.getName().startsWith(enabledworld.replace("*", ""))) { return false; + } } return true; }