Even after a decent number of years on Rails, I still make the occasional mistake of using the singular association form in the where
clause. Anybody else experiencing this?
Eg.
class User
belongs_to :account
end
User.joins(:account).where(account: { status: :active }) #should be accounts: