You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2023/03/26 17:03:35 UTC

[camel] branch main updated: camel-core - AdviceWithBuilder.maxDeep fix using 0 to disable depth. Thanks to Dmitrii Kriukov for reporting

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

davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new 6e3acba0d95 camel-core - AdviceWithBuilder.maxDeep fix using 0 to disable depth. Thanks to Dmitrii Kriukov for reporting
6e3acba0d95 is described below

commit 6e3acba0d95f0b8980e86eb0a3e4a13d18e905f3
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Sun Mar 26 19:03:19 2023 +0200

    camel-core - AdviceWithBuilder.maxDeep fix using 0 to disable depth. Thanks to Dmitrii Kriukov for reporting
---
 .../src/main/java/org/apache/camel/builder/AdviceWithBuilder.java      | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/core/camel-core-model/src/main/java/org/apache/camel/builder/AdviceWithBuilder.java b/core/camel-core-model/src/main/java/org/apache/camel/builder/AdviceWithBuilder.java
index 1756ecdb98c..23df690a99c 100644
--- a/core/camel-core-model/src/main/java/org/apache/camel/builder/AdviceWithBuilder.java
+++ b/core/camel-core-model/src/main/java/org/apache/camel/builder/AdviceWithBuilder.java
@@ -120,8 +120,9 @@ public class AdviceWithBuilder<T extends ProcessorDefinition<?>> {
         if (maxDeep == 0) {
             // disable it
             this.maxDeep = -1;
+        } else {
+            this.maxDeep = maxDeep;
         }
-        this.maxDeep = maxDeep;
         return this;
     }