From a01d1a93c434a6167502dc7a33774feb407b0f3f Mon Sep 17 00:00:00 2001 From: Lixfel Date: Sat, 29 Aug 2020 12:52:08 +0200 Subject: [PATCH] Fixing non loading items --- SpigotCore_14/src/de/steamwar/inventory/SWItem_14.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/SpigotCore_14/src/de/steamwar/inventory/SWItem_14.java b/SpigotCore_14/src/de/steamwar/inventory/SWItem_14.java index 684305d..35bab12 100644 --- a/SpigotCore_14/src/de/steamwar/inventory/SWItem_14.java +++ b/SpigotCore_14/src/de/steamwar/inventory/SWItem_14.java @@ -8,7 +8,11 @@ class SWItem_14 { private SWItem_14(){} static Material getMaterial(String material) { - return Material.valueOf("LEGACY_" + material); + try{ + return Material.valueOf(material); + }catch(IllegalArgumentException e){ + return Material.valueOf("LEGACY_" + material); + } } static Material getDye(int colorCode){ -- 2.39.5