Skip to content

Commit 3a7b70f

Browse files
authored
BE: issues/1462 fixed (#1463)
1 parent 9e1f9d6 commit 3a7b70f

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

api/src/main/java/io/kafbat/ui/service/index/LuceneTopicsIndex.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,10 @@ private Directory build(List<InternalTopic> topics) {
7474
doc.add(new LongPoint(FIELD_SIZE, topic.getSegmentSize()));
7575
if (topic.getTopicConfigs() != null && !topic.getTopicConfigs().isEmpty()) {
7676
for (InternalTopicConfig topicConfig : topic.getTopicConfigs()) {
77-
doc.add(new StringField(FIELD_CONFIG_PREFIX + "_" + topicConfig.getName(), topicConfig.getValue(),
78-
Field.Store.NO));
77+
if (topicConfig.getName() != null || topicConfig.getValue() != null) {
78+
doc.add(new StringField(FIELD_CONFIG_PREFIX + "_" + topicConfig.getName(), topicConfig.getValue(),
79+
Field.Store.NO));
80+
}
7981
}
8082
}
8183
doc.add(new StringField(FIELD_INTERNAL, String.valueOf(topic.isInternal()), Field.Store.NO));

0 commit comments

Comments
 (0)