aboutsummaryrefslogtreecommitdiffstats
path: root/app/models/refinery/blog_comment.rb
diff options
context:
space:
mode:
authorPhilip Arndt <parndt@gmail.com>2011-09-03 22:09:51 -0700
committerPhilip Arndt <parndt@gmail.com>2011-09-03 22:09:51 -0700
commit40be4f71ee425ee55ecedea96ff2b0dc510d71db (patch)
tree3ba02acc7861ef51045f0196dff6bac9efda40d5 /app/models/refinery/blog_comment.rb
parent80ca7c1bf99befac70803309e542a4db54f1f198 (diff)
parent6212e60f9e4d144f9a136f6c82b33abd47ddb237 (diff)
downloadrefinerycms-blog-40be4f71ee425ee55ecedea96ff2b0dc510d71db.tar.gz
refinerycms-blog-40be4f71ee425ee55ecedea96ff2b0dc510d71db.tar.bz2
refinerycms-blog-40be4f71ee425ee55ecedea96ff2b0dc510d71db.zip
Merge pull request #126 from enmasse-entertainment/fix-comments
Fix comments
Diffstat (limited to 'app/models/refinery/blog_comment.rb')
-rw-r--r--app/models/refinery/blog_comment.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/models/refinery/blog_comment.rb b/app/models/refinery/blog_comment.rb
index e5869a8..f7c1c84 100644
--- a/app/models/refinery/blog_comment.rb
+++ b/app/models/refinery/blog_comment.rb
@@ -19,6 +19,8 @@ module Refinery
scope :unmoderated, :conditions => {:state => nil}
scope :approved, :conditions => {:state => 'approved'}
scope :rejected, :conditions => {:state => 'rejected'}
+
+ self.per_page = Setting.find_or_set(:blog_comments_per_page, 10)
def avatar_url(options = {})
options = {:size => 60}
@@ -55,7 +57,7 @@ module Refinery
end
before_create do |comment|
- unless BlogComment::Moderation.enabled?
+ unless Moderation.enabled?
comment.state = comment.ham? ? 'approved' : 'rejected'
end
end