fix the node delete case

fix the node delete case when there is only one child.