Files
fizzy/app/models/concerns/threadable.rb
T
2024-10-23 14:10:04 -06:00

12 lines
264 B
Ruby

module Threadable
extend ActiveSupport::Concern
included do
has_one :thread_entry, as: :threadable, dependent: :destroy
after_create { create_thread_entry! bubble: bubble }
after_update { bubble.touch }
after_touch { bubble.touch }
end
end