mirror of
https://github.com/wahyd4/libr-2.git
synced 2026-08-09 13:26:05 +10:00
7 lines
168 B
Ruby
7 lines
168 B
Ruby
class Comment < ActiveRecord::Base
|
|
|
|
has_many :likes, as: :likable
|
|
belongs_to :commentable, polymorphic: true, counter_cache: :comments_count
|
|
belongs_to :user
|
|
end
|