Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 2 additions & 9 deletions www/searchutil.php
Original file line number Diff line number Diff line change
Expand Up @@ -285,15 +285,8 @@ function doSearch($db, $term, $searchType, $sortby, $limit, $browse)
$baseWhere = "";
$groupBy = "";
$baseOrderBy = "";
if ($browse && ($sortby == "" || $sortby == "ratu" || $sortby == "ratd" || $sortby == "rcu")) {
// when sorting by highest/lowest/most ratings, we can optimize by
// fetching the top N from the gameRatingsView
$tableList = "games
join ".getGameRatingsView($db)." on games.id = gameid";
} else {
$tableList = "games
left join ".getGameRatingsView($db)." on games.id = gameid";
}
$tableList = "games
join ".getGameRatingsView($db)." on games.id = gameid";
$matchCols = "title, author, `desc`, tags";
$likeCol = "title";
$summaryDesc = "Games";
Expand Down