From 22ca1863fde3dca252a456a78b733f2ab1c7fd31 Mon Sep 17 00:00:00 2001 From: nossr50 Date: Tue, 26 Feb 2019 11:37:21 -0800 Subject: [PATCH] fix NPE for anvil, salvage block, detonator item --- src/main/java/com/gmail/nossr50/config/MainConfig.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/gmail/nossr50/config/MainConfig.java b/src/main/java/com/gmail/nossr50/config/MainConfig.java index 57bef187d..1ee3a490f 100644 --- a/src/main/java/com/gmail/nossr50/config/MainConfig.java +++ b/src/main/java/com/gmail/nossr50/config/MainConfig.java @@ -1003,7 +1003,8 @@ public class MainConfig extends ConfigValidated { /* Mining */ public Material getDetonatorItem() { - return Material.matchMaterial(getStringValue(SKILLS, MINING, DETONATOR + NAME, FLINT_AND_STEEL)); + //Flint and steel + return Material.matchMaterial(getStringValue(SKILLS, MINING, DETONATOR + NAME)); } /* Repair */ @@ -1020,7 +1021,8 @@ public class MainConfig extends ConfigValidated { } public Material getRepairAnvilMaterial() { - return Material.matchMaterial(getStringValue(SKILLS, REPAIR, ANVIL_MATERIAL, IRON_BLOCK)); + //Iron block + return Material.matchMaterial(getStringValue(SKILLS, REPAIR, ANVIL_MATERIAL)); } public boolean getRepairConfirmRequired() { @@ -1041,7 +1043,8 @@ public class MainConfig extends ConfigValidated { } public Material getSalvageAnvilMaterial() { - return Material.matchMaterial(getStringValue(SKILLS, SALVAGE, ANVIL_MATERIAL, GOLD_BLOCK)); + //Gold Block + return Material.matchMaterial(getStringValue(SKILLS, SALVAGE, ANVIL_MATERIAL)); } public boolean getSalvageConfirmRequired() {