From f38c81aa2ad70634e13586968f5a7ee5e3f27386 Mon Sep 17 00:00:00 2001 From: Jordan Date: Fri, 7 Jul 2023 17:27:10 +0100 Subject: [PATCH] fix: correctly invalidate mask after a plot is merged (#2333) --- .../bukkit/regions/plotsquared/PlotSquaredFeature.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/worldedit-bukkit/src/main/java/com/fastasyncworldedit/bukkit/regions/plotsquared/PlotSquaredFeature.java b/worldedit-bukkit/src/main/java/com/fastasyncworldedit/bukkit/regions/plotsquared/PlotSquaredFeature.java index 46ba12f68..e28602292 100644 --- a/worldedit-bukkit/src/main/java/com/fastasyncworldedit/bukkit/regions/plotsquared/PlotSquaredFeature.java +++ b/worldedit-bukkit/src/main/java/com/fastasyncworldedit/bukkit/regions/plotsquared/PlotSquaredFeature.java @@ -211,8 +211,9 @@ public class PlotSquaredFeature extends FaweMaskManager { @Override public boolean isValid(Player player, MaskType type, boolean notify) { - if ((!connectedPlots.refersTo(plot.getConnectedPlots()) && !singlePlot) || (Settings.Done.RESTRICT_BUILDING && DoneFlag.isDone( - plot))) { + if ((!connectedPlots.refersTo(plot.getConnectedPlots()) && (!singlePlot || plot + .getConnectedPlots() + .size() > 1)) || (Settings.Done.RESTRICT_BUILDING && DoneFlag.isDone(plot))) { return false; } return isAllowed(player, plot, type, notify);