diff --git a/src/main/java/de/epiceric/shopchest/listeners/ShopItemListener.java b/src/main/java/de/epiceric/shopchest/listeners/ShopItemListener.java index a0069e9..bb0748a 100644 --- a/src/main/java/de/epiceric/shopchest/listeners/ShopItemListener.java +++ b/src/main/java/de/epiceric/shopchest/listeners/ShopItemListener.java @@ -64,7 +64,7 @@ public class ShopItemListener implements Listener { double itemDistanceSquared = plugin.getShopChestConfig().maximal_item_distance; itemDistanceSquared *= itemDistanceSquared; - World w = p.getWorld(); + World w = playerLocation.getWorld(); for (Shop shop : shopUtils.getShops()) { Location shopLocation = shop.getLocation();