Nicolas Bally 27d7568a83 comments
2015-04-13 15:51:41 +02:00

18 lines
325 B
Ruby

# -*- encoding : utf-8 -*-
class Comment < ActiveRecord::Base
include ActsAsCommentable::Comment
belongs_to :commentable, :polymorphic => true
validates :pseudo, :presence => true
validates :comment, :presence => true
scope :recents, -> {where("enabled = ?",true ).order("created_at ASC")}
acts_as_tree
end