From a04012d9bfdda59405f446f5e76b49775c947830 Mon Sep 17 00:00:00 2001 From: TheMode Date: Sat, 25 Jun 2022 13:01:16 +0200 Subject: [PATCH] Fix npe Signed-off-by: TheMode --- src/main/java/net/minestom/server/tag/TagHandlerImpl.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/net/minestom/server/tag/TagHandlerImpl.java b/src/main/java/net/minestom/server/tag/TagHandlerImpl.java index 1f8efc4f1..6793ed787 100644 --- a/src/main/java/net/minestom/server/tag/TagHandlerImpl.java +++ b/src/main/java/net/minestom/server/tag/TagHandlerImpl.java @@ -76,7 +76,8 @@ final class TagHandlerImpl implements TagHandler { } else { synchronized (this) { node = traversePathWrite(root, tag, false); - if (node != null) node.entries.remove(tagIndex); + if (node == null) return; + node.entries.remove(tagIndex); } } node.invalidate();