remove edges from subtree