Remove some manual iteration