Extract method to reuse removal of child nodes