diff options
author | Evan Prodromou <evan@controlyourself.ca> | 2009-03-05 11:04:16 -0800 |
---|---|---|
committer | Evan Prodromou <evan@controlyourself.ca> | 2009-03-05 11:04:16 -0800 |
commit | 6ce7d0c567b23d3bec035a9c4428399bdfdb896b (patch) | |
tree | ae887738020b1c67cd57aa247f4c326fe331a048 /lib/popularnoticesection.php | |
parent | b9781258bbfaac0e7fc91af4f77f1f340274a88e (diff) | |
parent | 3087e4ad5dfbccb7218c12ca747e1dbcf3a6415c (diff) |
Merge branch '0.7.x' of git@gitorious.org:laconica/dev into 0.7.x
Diffstat (limited to 'lib/popularnoticesection.php')
-rw-r--r-- | lib/popularnoticesection.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/popularnoticesection.php b/lib/popularnoticesection.php index f7fb93554..0505f0fa9 100644 --- a/lib/popularnoticesection.php +++ b/lib/popularnoticesection.php @@ -54,10 +54,12 @@ class PopularNoticeSection extends NoticeSection $weightexpr='sum(exp(-(now() - fave.modified) / %s))'; } - $qry = 'SELECT notice.id, '. + $qry = 'SELECT notice.*, '. $weightexpr . ' as weight ' . 'FROM notice JOIN fave ON notice.id = fave.notice_id ' . - 'GROUP BY notice.id ' . + 'GROUP BY notice.id,notice.profile_id,notice.content,notice.uri,' . + 'notice.rendered,notice.url,notice.created,notice.modified,' . + 'notice.reply_to,notice.is_local,notice.source ' . 'ORDER BY weight DESC'; $offset = 0; |