From 2f1d9ad82cae64b1012f4f105e98b01bfc0db5ee Mon Sep 17 00:00:00 2001 From: KHobbits Date: Sun, 29 Jan 2012 21:44:15 +0000 Subject: [PATCH] Prevent /home bed, if the bed was later destroyed. --- .../src/com/earth2me/essentials/commands/Commandhome.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandhome.java b/Essentials/src/com/earth2me/essentials/commands/Commandhome.java index ebe57adf7..f14422efd 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandhome.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandhome.java @@ -48,7 +48,7 @@ public class Commandhome extends EssentialsCommand if ("bed".equalsIgnoreCase(homeName)) { final Location bed = player.getBedSpawnLocation(); - if (bed != null) + if (bed != null && bed.getBlock().getType() == Material.BED_BLOCK) { user.getTeleport().teleport(bed, charge, TeleportCause.COMMAND); throw new NoChargeException();