Skip to content

Commit 5870e9c

Browse files
authored
Merge pull request linuxfrorg#275 from Trim/fix-amr-edit-for-comment-by-user-with-closed-account
comments: wikify_body set nofollow if user account has been closed
2 parents bf40c52 + 94b1bba commit 5870e9c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/models/comment.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class Comment < ActiveRecord::Base
3939

4040
wikify_attr :body
4141
def wikify_body
42-
nofollow = user.account.karma < 50
42+
nofollow = user.account.blank? || user.account.karma < 50
4343
self.body = wikify(wiki_body, nofollow: nofollow)
4444
end
4545

0 commit comments

Comments
 (0)