From 618b1ab66721066c9b56057d9fd586e77e054223 Mon Sep 17 00:00:00 2001 From: "Ricardo M." Date: Fri, 13 Sep 2024 14:32:29 +0200 Subject: [PATCH] fix(CatalogGenerator): Ignore 'enum' property for multiValue param In Camel 4.8.0, there's an enum property over a multiValue parameter, making the configuration form to render a selector instead of a metadata editor. --- .../io/kaoto/camelcatalog/generator/CamelCatalogProcessor.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/catalog-generator/src/main/java/io/kaoto/camelcatalog/generator/CamelCatalogProcessor.java b/packages/catalog-generator/src/main/java/io/kaoto/camelcatalog/generator/CamelCatalogProcessor.java index 9e677a28d..227fd32a2 100644 --- a/packages/catalog-generator/src/main/java/io/kaoto/camelcatalog/generator/CamelCatalogProcessor.java +++ b/packages/catalog-generator/src/main/java/io/kaoto/camelcatalog/generator/CamelCatalogProcessor.java @@ -174,7 +174,7 @@ private void generatePropertiesSchema(ObjectNode parent) { } } - if (property.has("enum")) { + if (property.has("enum") && !"object".equals(propertyType)) { property.withArray("/enum") .forEach(e -> propertySchema.withArray("/enum").add(e)); if (!propertySchema.has("type") || "object".equals(propertySchema.get("type").asText())) {