Fix thumbnail appearing next to deleted comments

This commit is contained in:
Toks
2015-07-23 09:57:13 -04:00
parent 95e10e3acd
commit 52c73efc28
3 changed files with 24 additions and 16 deletions

View File

@@ -32,6 +32,10 @@ class Comment < ActiveRecord::Base
where("score >= ?", user.comment_threshold)
end
def undeleted
where("is_deleted = false")
end
def post_tags_match(query)
PostQueryBuilder.new(query).build(self.joins(:post)).reorder("")
end