Clone nodes when creating a new package tree after subtraction.
Refactor.
Refactor.