-
Bug
-
Resolution: Done
-
Critical
-
3.1.1.Final
-
None
Executing org.modeshape.jcr.JcrSession.move("/test1", "/test2"), in a in memory repository, throw exception caused by: javax.jcr.ItemNotFoundException
at org.modeshape.jcr.JcrRootNode.getParent(JcrRootNode.java:88)
at org.modeshape.jcr.JcrSession.move(JcrSession.java:946)
I'm a newbie of modeshape so I don't know if it's the desired behavior, but to fix is sufficient to check if the node is the root before call getParent().
destAncestor = !destAncestor.isRoot() ? destAncestor.getParent() : destAncestor;