Story: bump up hotness for stories authored by users

This commit is contained in:
Carl Chenet 2017-05-20 14:50:03 +02:00
parent d975593aed
commit a67236d097

View file

@ -185,7 +185,8 @@ class Story < ActiveRecord::Base
end
def calculated_hotness
base = self.tags.map{|t| t.hotness_mod }.sum
base = self.tags.map{|t| t.hotness_mod }.sum +
(self.user_is_author ? 0.25 : 0.0)
# give a story's comment votes some weight, ignoring submitter's comments
cpoints = self.comments.