Sha256: 56a41e68eb178f4da64ae3d1037c6758c2bf09d49f897c2e2fc4a1a8d845acf3
Contents?: true
Size: 351 Bytes
Versions: 10
Compression:
Stored size: 351 Bytes
Contents
class User < ActiveRecord::Base include TheComments::User include TheComments::Commentable authenticates_with_sorcery! has_many :posts # can be replaced to TheCommentsUser as default def admin? self == User.first end def comments_admin? admin? end def comments_moderator? comment id == comment.holder_id end end
Version data entries
10 entries across 10 versions & 3 rubygems