From 1a3fe1426a4a96def27e5de496a14f706f9c37ae Mon Sep 17 00:00:00 2001 From: boy0001 Date: Sat, 21 Mar 2015 00:53:24 +1100 Subject: [PATCH] Fixed NPE --- .../java/com/intellectualcrafters/plot/commands/Merge.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PlotSquared/src/main/java/com/intellectualcrafters/plot/commands/Merge.java b/PlotSquared/src/main/java/com/intellectualcrafters/plot/commands/Merge.java index 8977d8eb2..731ded1bc 100644 --- a/PlotSquared/src/main/java/com/intellectualcrafters/plot/commands/Merge.java +++ b/PlotSquared/src/main/java/com/intellectualcrafters/plot/commands/Merge.java @@ -141,11 +141,11 @@ public class Merge extends SubCommand { final UUID u1 = plot.owner; for (final PlotId myid : plots) { final Plot myplot = PlotSquared.getPlots(world).get(myid); - UUID u2 = myplot.owner; - if (myplot == null || u2 == null) { + if (myplot == null || myplot.owner == null) { MainUtil.sendMessage(plr, C.NO_PERM_MERGE.s().replaceAll("%plot%", myid.toString())); return false; } + UUID u2 = myplot.owner; if (u2.equals(u1)) { continue; }