When you call each on a Hash with one block variable, each entry in the hash gets made into an array. That .each on line 175 shoud be .each_value — the values in the hash are hashes.
Of course, this has been broken a long time and fixing it causes a lot of invalid data in production.
https://github.com/umts/stop-project/blob/c721d5ebc2f9f220f13c819257cadff2bad33175/app/models/bus_stop.rb#L175-L179
When you call
each
on aHash
with one block variable, each entry in the hash gets made into an array. That.each
on line 175 shoud be.each_value
— the values in the hash are hashes.Of course, this has been broken a long time and fixing it causes a lot of invalid data in production.