From 4aefc23bb8074303c713a94d7f583ba4020dda04 Mon Sep 17 00:00:00 2001 From: Nassim Jahnke Date: Sun, 10 Dec 2023 12:16:53 +0100 Subject: [PATCH] Fix npe --- .../protocol1_20_3to1_20_2/util/ComponentConverter.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/src/main/java/com/viaversion/viaversion/protocols/protocol1_20_3to1_20_2/util/ComponentConverter.java b/common/src/main/java/com/viaversion/viaversion/protocols/protocol1_20_3to1_20_2/util/ComponentConverter.java index f78489168..3017dd3e9 100644 --- a/common/src/main/java/com/viaversion/viaversion/protocols/protocol1_20_3to1_20_2/util/ComponentConverter.java +++ b/common/src/main/java/com/viaversion/viaversion/protocols/protocol1_20_3to1_20_2/util/ComponentConverter.java @@ -289,7 +289,7 @@ public final class ComponentConverter { private static void removeComponentType(final JsonObject object) { final JsonElement type = object.remove("type"); - if (!type.isJsonPrimitive()) { + if (type == null || !type.isJsonPrimitive()) { return; }