From 6aa3f7c1b7cd1c5a7acba7bb1415a19138a6e6da Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 10 May 2022 09:02:57 +0200 Subject: [PATCH] Update Bukkit/src/main/java/com/plotsquared/bukkit/queue/BukkitQueueCoordinator.java Co-authored-by: Hannes Greule --- .../com/plotsquared/bukkit/queue/BukkitQueueCoordinator.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/queue/BukkitQueueCoordinator.java b/Bukkit/src/main/java/com/plotsquared/bukkit/queue/BukkitQueueCoordinator.java index ed6275750..7dcb1a5a0 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/queue/BukkitQueueCoordinator.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/queue/BukkitQueueCoordinator.java @@ -269,8 +269,8 @@ public class BukkitQueueCoordinator extends BasicQueueCoordinator { BlockData blockData = BukkitAdapter.adapt(block); Block existing; // Assume a chunk object has been given only when it should have been. - if (getChunkObject() instanceof Chunk) { - existing = ((Chunk) getChunkObject()).getBlock(x & 15, y, z & 15); + if (getChunkObject() instanceof Chunk chunkObject) { + existing = chunkObject.getBlock(x & 15, y, z & 15); } else { existing = getBukkitWorld().getBlockAt(x, y, z); }