I’d like to nitpick that User.where(name: "schneems").first
can be slow because it searches through the whole table and we care only about first result. User.where(name: "schneems").limit(1)
is better
I’d like to nitpick that User.where(name: "schneems").first
can be slow because it searches through the whole table and we care only about first result. User.where(name: "schneems").limit(1)
is better