From f726d07f1150e5cf6665ec40bccb2b2e2d265251 Mon Sep 17 00:00:00 2001 From: feildmaster Date: Mon, 24 Dec 2012 14:32:08 -0600 Subject: [PATCH] Fix Skull BlockState setting illegal values on owner. --- src/main/java/org/bukkit/craftbukkit/block/CraftSkull.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftSkull.java b/src/main/java/org/bukkit/craftbukkit/block/CraftSkull.java index 2f2564f202..0f3e0d8ff1 100644 --- a/src/main/java/org/bukkit/craftbukkit/block/CraftSkull.java +++ b/src/main/java/org/bukkit/craftbukkit/block/CraftSkull.java @@ -148,7 +148,7 @@ public class CraftSkull extends CraftBlockState implements Skull { } public boolean setOwner(String name) { - if (name != null && name.length() > MAX_OWNER_LENGTH) { + if (name == null || name.length() > MAX_OWNER_LENGTH) { return false; } player = name; @@ -176,7 +176,7 @@ public class CraftSkull extends CraftBlockState implements Skull { this.skullType = skullType; if (skullType != SkullType.PLAYER) { - player = null; + player = ""; } }