From 4ba69135cb01e75f47381dd2bdea118a237b456e Mon Sep 17 00:00:00 2001 From: Acrobot Date: Tue, 29 Jan 2013 21:01:46 +0100 Subject: [PATCH] Fixed NPE in PermissionCheck pre shop creation --- .../ChestShop/Listeners/PreShopCreation/PermissionChecker.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/com/Acrobot/ChestShop/Listeners/PreShopCreation/PermissionChecker.java b/com/Acrobot/ChestShop/Listeners/PreShopCreation/PermissionChecker.java index 009dca0..ca9cac6 100644 --- a/com/Acrobot/ChestShop/Listeners/PreShopCreation/PermissionChecker.java +++ b/com/Acrobot/ChestShop/Listeners/PreShopCreation/PermissionChecker.java @@ -33,8 +33,7 @@ public class PermissionChecker implements Listener { ItemStack item = MaterialUtil.getItem(itemLine); - if (!Permission.has(player, SHOP_CREATION_ID + Integer.toString(item.getTypeId()))) { - event.setOutcome(NO_PERMISSION); + if (item == null || Permission.has(player, SHOP_CREATION_ID + Integer.toString(item.getTypeId()))) { return; }