From b134dd3b1c822e3f74576e93ab43db98526996fa Mon Sep 17 00:00:00 2001 From: Olivia Date: Sat, 25 Dec 2021 16:16:30 -0600 Subject: [PATCH] fix: Return early in banner translation if tag is null (#2729) --- .../level/block/entity/BannerBlockEntityTranslator.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/core/src/main/java/org/geysermc/geyser/translator/level/block/entity/BannerBlockEntityTranslator.java b/core/src/main/java/org/geysermc/geyser/translator/level/block/entity/BannerBlockEntityTranslator.java index 9cd1981c6..249271f99 100644 --- a/core/src/main/java/org/geysermc/geyser/translator/level/block/entity/BannerBlockEntityTranslator.java +++ b/core/src/main/java/org/geysermc/geyser/translator/level/block/entity/BannerBlockEntityTranslator.java @@ -41,6 +41,10 @@ public class BannerBlockEntityTranslator extends BlockEntityTranslator implement builder.put("Base", 15 - bannerColor); } + if (tag == null) { + return; + } + if (tag.contains("Patterns")) { ListTag patterns = tag.get("Patterns"); if (patterns.equals(BannerTranslator.OMINOUS_BANNER_PATTERN)) {