forgeplus/app/models/watcher.rb

5 lines
136 B
Ruby
Raw Permalink Normal View History

2020-03-09 00:40:16 +08:00
class Watcher < ApplicationRecord
belongs_to :user
belongs_to :watchable, polymorphic: true, counter_cache: :watchers_count
end