From 769538bef36b03df8c99acc2878d2208eec7c0bd Mon Sep 17 00:00:00 2001 From: yoyosource Date: Sat, 15 Jan 2022 11:33:03 +0100 Subject: [PATCH] Fix SchematicCommand --- .../schematicsystem/commands/SchematicCommand.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/SchematicCommand.java b/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/SchematicCommand.java index a2a33f5..0b9cc05 100644 --- a/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/SchematicCommand.java +++ b/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/SchematicCommand.java @@ -293,9 +293,10 @@ public class SchematicCommand extends SWCommand { } i++; } + } else { + predicates.add(node -> node.getName().contains(current)); + nameList.add(current); } - predicates.add(node -> node.getName().contains(current)); - nameList.add(current); i++; } @@ -674,7 +675,9 @@ public class SchematicCommand extends SWCommand { } return mapper.tabCompletes(commandSender, strings, s); } - return Collections.singletonList(s); + List list = new ArrayList<>(searchMapper.keySet()); + list.add(s); + return list; } }; }