You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@causeway.apache.org by ah...@apache.org on 2024/04/03 14:50:36 UTC

(causeway) 01/02: CAUSEWAY-3711: fixes optimized route (again)

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

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/causeway.git

commit 6769e610c0892fb731b52145c29d0aa060030759
Author: andi-huber <ah...@apache.org>
AuthorDate: Wed Apr 3 16:49:10 2024 +0200

    CAUSEWAY-3711: fixes optimized route (again)
---
 .../src/main/java/org/apache/causeway/applib/graph/tree/TreeNode.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/api/applib/src/main/java/org/apache/causeway/applib/graph/tree/TreeNode.java b/api/applib/src/main/java/org/apache/causeway/applib/graph/tree/TreeNode.java
index 438b08840e..73504574c4 100644
--- a/api/applib/src/main/java/org/apache/causeway/applib/graph/tree/TreeNode.java
+++ b/api/applib/src/main/java/org/apache/causeway/applib/graph/tree/TreeNode.java
@@ -154,7 +154,7 @@ public class TreeNode<T> implements Vertex<T> {
          * observe: the relative path /p3 would point to the sub-node itself
          */
         return absolutePath.startsWith(treePath)
-                ? resolveRelative(absolutePath.subPath(treePath.size()))
+                ? resolveRelative(absolutePath.subPath(treePath.size() - 1))
                 : rootNode.resolveRelative(absolutePath);
     }