Permalink
Browse files

Merge branch 'master' of GitHub:joindin/joind.in into oauth2

Conflicts:
	src/api-v2/models/EventMapper.php
  • Loading branch information...
2 parents e6dc04e + dab5d92 commit 9c98a3418ecc17f7bf0c78689e69961f6f1926ec @lornajane committed Apr 7, 2012
Showing with 2 additions and 3 deletions.
  1. +1 −2 src/api-v2/models/EventMapper.php
  2. +1 −1 src/system/application/models/event_model.php
@@ -164,8 +164,7 @@ public function getEventList($resultsperpage, $start, $verbose = false)
*/
public function getHotEventList($resultsperpage, $start, $verbose = false)
{
- $order = '(((attendee_count + event_comments_count) * 0.5)
- - EXP(GREATEST(1,score)/20)) desc';
+ $order = "score - ((event_comments_count + attendee_count + 1) / 5)";
$results = $this->getEvents($resultsperpage, $start, null, $order);
if ($results) {
$retval = $this->transformResults($results, $verbose);
@@ -217,7 +217,7 @@ function getEventsOfType($type, $limit = NULL) {
if ($type == "hot") {
// if you change this, change the API too please
- $order_by = "(((num_attend + num_comments) * 0.5) - EXP(GREATEST(1, score)/20)) desc";
+ $order_by = "score - ((num_comments + num_attend + 1) / 5)";
}
if ($type == "upcoming") {

0 comments on commit 9c98a34

Please sign in to comment.