cleaned up the iterators a lot