From 0ee3993bbd93ec1c2b30b2aa96f0d7e306b4282d Mon Sep 17 00:00:00 2001 From: kyonRay Date: Wed, 23 Oct 2024 15:03:19 +0800 Subject: [PATCH] (jline): fix jline not complete sysconfig bug. --- src/main/java/console/command/JlineUtils.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/main/java/console/command/JlineUtils.java b/src/main/java/console/command/JlineUtils.java index ed2f40aa..28815689 100644 --- a/src/main/java/console/command/JlineUtils.java +++ b/src/main/java/console/command/JlineUtils.java @@ -214,7 +214,15 @@ private static List generateComplters(Client client) { if (group.isPresent() && !group.get().getNodeList().isEmpty()) { group.get() .getNodeList() - .forEach(groupNodeInfo -> keys.addAll(groupNodeInfo.getFeatureKeys())); + .forEach( + groupNodeInfo -> { + if (groupNodeInfo.getFeatureKeys() != null) { + keys.addAll(groupNodeInfo.getFeatureKeys()); + } + if (groupNodeInfo.getSupportConfigs() != null) { + keys.addAll(groupNodeInfo.getSupportConfigs()); + } + }); } } catch (Exception ignored) { logger.info("Failed to get group info list, skip feature keys.");