Fix renameAndRestructure.
Switch to iterators now complete