From 57ada4b9e0adeabcf5719412444e98362a1b8564 Mon Sep 17 00:00:00 2001 From: Lixfel Date: Mon, 20 Jan 2020 07:07:19 +0100 Subject: [PATCH] Hotfix Schemtype fromDB NPE --- SpigotCore_Main/src/de/steamwar/sql/SchematicType.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/SpigotCore_Main/src/de/steamwar/sql/SchematicType.java b/SpigotCore_Main/src/de/steamwar/sql/SchematicType.java index 068ceeb..32c81dd 100644 --- a/SpigotCore_Main/src/de/steamwar/sql/SchematicType.java +++ b/SpigotCore_Main/src/de/steamwar/sql/SchematicType.java @@ -81,9 +81,7 @@ public class SchematicType { } public static SchematicType fromDB(String input){ - if(input == null) - return null; - return fromDB.get(input.toLowerCase()); + return fromDB.getOrDefault(input.toLowerCase(), null); } public static List values(){