From 6cb466bc837143086c73336f6e02fbd6664d63bc Mon Sep 17 00:00:00 2001 From: joshua stein Date: Thu, 20 Sep 2012 10:59:30 -0500 Subject: [PATCH] shrink story hotness window down to 24 hours as we are growing --- app/models/story.rb | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/models/story.rb b/app/models/story.rb index e3975ed..4e5db7f 100644 --- a/app/models/story.rb +++ b/app/models/story.rb @@ -252,9 +252,8 @@ class Story < ActiveRecord::Base seconds = self.created_at.to_i - 398995200 - # XXX: while we're slow, allow a window of 36 hours. as the site grows, - # shrink this down to 12 or so. - window = 60 * 60 * 36 + # TODO: as the site grows, shrink this down to 12 or so. + window = 60 * 60 * 24 return -(order + (sign * (seconds.to_f / window))).round(7) end