- need to remove the entire path if not children exists
- adding the pruning for the entire path