diff --git a/src/main/java/com/songoda/ultimatestacker/tasks/StackingTask.java b/src/main/java/com/songoda/ultimatestacker/tasks/StackingTask.java index 998f4a3..96793d5 100644 --- a/src/main/java/com/songoda/ultimatestacker/tasks/StackingTask.java +++ b/src/main/java/com/songoda/ultimatestacker/tasks/StackingTask.java @@ -216,7 +216,8 @@ public class StackingTask extends BukkitRunnable { if (isStack) return; // Check our WorldGuard flag. - if (WorldGuardHook.isEnabled() && !WorldGuardHook.getBooleanFlag(livingEntity.getLocation(), "mob-stacking")) + Boolean flag = WorldGuardHook.isEnabled() ? WorldGuardHook.getBooleanFlag(livingEntity.getLocation(), "mob-stacking") : null; + if (flag != null && !flag) return; // Remove all stacked entities from our stackable friends.