Bug fix: delNode should remove the node from its parent's children set