From 2b5ba630879afe4c4d38fe68713a113115a0bbfc Mon Sep 17 00:00:00 2001 From: joshua stein Date: Wed, 10 Feb 2016 16:12:11 -0600 Subject: [PATCH] Comment: if user is banned, make gone text reflect that --- app/models/comment.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/models/comment.rb b/app/models/comment.rb index 36b34a1..dba36ca 100644 --- a/app/models/comment.rb +++ b/app/models/comment.rb @@ -284,6 +284,8 @@ class Comment < ActiveRecord::Base "Thread removed by moderator " << self.moderation.try(:moderator).try(:username).to_s << ": " << (self.moderation.try(:reason) || "No reason given") + elsif self.user.is_banned? + "Comment from banned user removed" else "Comment removed by author" end