jeudi 14 mai 2015

Do I treat this as an array or a hash?

I have two models: class User < ActiveRecord::Base and class Tips < ActiveRecord::Base. If I write:

user.each do |...|

or

tips.each.do |...|

Should I treat either as an array or a hash? How will I know?

I would post the model for user and tips, but they are very long. Any help is appreciated! Thanks in advance!!!

Aucun commentaire:

Enregistrer un commentaire