Fix issue where Iterator was not Iterable because of scope error