Fix bug when using iterators to specify children.