fixes reset looping through a hash and not array