Closed ilgiz-badamshin closed 3 years ago
@ilgiz-badamshin you are right. It's a bug. Thank you for reporting.
If you have ideas how to fix it, PR is welcome!
@ilgiz-badamshin thank you for your PRs! I merged them and created a new release with the changes - see v 1.5.1
From documentation:
For example method: moveAsFirstChildOf. If source node and dest node has different rootId, then called moveBetweenTrees, that call insertAsFirstChildOf, that throw exception: "Cannot insert the node that has its place in the tree", becouse node exists and we can't use methotds insertXXX.
So no one moveXXX from different trees is not working. Maybe need to call detach(), before insertXXX methods? Or i some where have mistake?