syntax error in concern
This commit is contained in:
parent
8d40c03cce
commit
0b110cf469
1 changed files with 3 additions and 1 deletions
|
@ -2,7 +2,9 @@
|
|||
module Attachable
|
||||
extend ActiveSupport::Concern
|
||||
|
||||
has_many :attachments, as: :attachable, dependent: :destroy
|
||||
included do
|
||||
has_many :attachments, as: :attachable, dependent: :destroy
|
||||
end
|
||||
|
||||
def images
|
||||
attachments.where(file_content_type: self.image_types)
|
||||
|
|
Loading…
Add table
Reference in a new issue