This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch worktree-snazzy-petting-map
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 8b595a7ce400a0e1ecf2ae7a20e039d36bc93807
Author: Claus Ibsen <[email protected]>
AuthorDate: Sat Jul 11 10:20:02 2026 +0200

    CAMEL-23992: camel-yaml-dsl - Fix inverted $ref check in 
extractRequiredFromComposition
    
    Co-Authored-By: Claude Opus 4.6 <[email protected]>
    Signed-off-by: Claus Ibsen <[email protected]>
---
 .../java/org/apache/camel/maven/dsl/yaml/GenerateYamlSchemaMojo.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/dsl/camel-yaml-dsl/camel-yaml-dsl-maven-plugin/src/main/java/org/apache/camel/maven/dsl/yaml/GenerateYamlSchemaMojo.java
 
b/dsl/camel-yaml-dsl/camel-yaml-dsl-maven-plugin/src/main/java/org/apache/camel/maven/dsl/yaml/GenerateYamlSchemaMojo.java
index 3ddafcf93a06..2fd42f59817f 100644
--- 
a/dsl/camel-yaml-dsl/camel-yaml-dsl-maven-plugin/src/main/java/org/apache/camel/maven/dsl/yaml/GenerateYamlSchemaMojo.java
+++ 
b/dsl/camel-yaml-dsl/camel-yaml-dsl-maven-plugin/src/main/java/org/apache/camel/maven/dsl/yaml/GenerateYamlSchemaMojo.java
@@ -578,7 +578,7 @@ public class GenerateYamlSchemaMojo extends 
GenerateYamlSupportMojo {
         }
 
         composition.forEach(compositionEntry -> {
-            if (!compositionEntry.has("$ref")) {
+            if (compositionEntry.has("$ref")) {
                 String parentName = 
StringHelper.after(compositionEntry.get("$ref").asText(), "/definitions/");
                 ObjectNode referredObject = definitions.withObject("/" + 
parentName);
                 extractRequiredFromComposition(negations, referredObject);

Reply via email to