From c00057237a0cfa2e2943eb99a7166eb946d7b67f Mon Sep 17 00:00:00 2001 From: Madeline Miller Date: Sat, 8 Jul 2023 17:35:42 +1000 Subject: [PATCH] Fixed one final bug found in testing --- .../worldedit/extension/factory/parser/DefaultBlockParser.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/worldedit-core/src/main/java/com/sk89q/worldedit/extension/factory/parser/DefaultBlockParser.java b/worldedit-core/src/main/java/com/sk89q/worldedit/extension/factory/parser/DefaultBlockParser.java index 3a6d2657ea..f5216d9c68 100644 --- a/worldedit-core/src/main/java/com/sk89q/worldedit/extension/factory/parser/DefaultBlockParser.java +++ b/worldedit-core/src/main/java/com/sk89q/worldedit/extension/factory/parser/DefaultBlockParser.java @@ -302,7 +302,7 @@ private BaseBlock parseLogic(String input, ParserContext context) throws InputPa if (stateStart + 1 >= blockAndExtraData[0].length()) { throw new InputParseException(TranslatableComponent.of("worldedit.error.parser.hanging-lbracket", TextComponent.of(stateStart))); } - int stateEnd = blockAndExtraData[0].lastIndexOf(']'); + int stateEnd = blockAndExtraData[0].indexOf(']'); if (stateEnd < 0) { throw new InputParseException(TranslatableComponent.of("worldedit.error.parser.missing-rbracket")); }