I recommend you consider switching to using has_many :items, :through => :link_table
It's become the new standard and it's a great approach because you get more flexibility 'baked in' and the structure is also ready for easy expansion and growth without major rework, e.g. adding new attributes is very easy. 'new attributes' are frequently date fields.
So you can add the regular timestamps fields (created and updated) and people also find other date fields like 'completed_on', 'authorized_on', 'terminated_on', 'activated_on', 'sold_on', etc. useful, depending on the application use cases.
class Image < ActiveRecord::Base
has_many :image_tags
has_many :tags, :through => :image_tags
end
class ImageTag < ActiveRecord::Base
belongs_to :image
belongs_to :tag
end
class Tag < ActiveRecord::Base
has_many :image_tags
has_many :images, :through => :image_tags
end
You will still see a lot of examples of HABTM and it does still work. There are certainly cases where it may still make sense to use it but as HMT does them anyway, KISS says use 'one way'.