lib/reviewed/product.rb in reviewed-0.1.26 vs lib/reviewed/product.rb in reviewed-0.1.27
- old
+ new
@@ -2,9 +2,10 @@
module Reviewed
class Product < Base
has_many :attachments
has_many :manufacturer_specs
+ has_one :brand
def attachments(tag=nil)
if tag.present?
@attributes.attachments.select do |attachment|
attachment_tags = attachment.tags || []