69
This commit is contained in:
@@ -97,11 +97,11 @@ export default (router, tpl) => {
|
||||
`;
|
||||
|
||||
const favotop = await db`
|
||||
select favorites.item_id, count(*) favs
|
||||
select favorites.item_id as id, items.slug, count(*) favs
|
||||
from favorites
|
||||
join items on items.id = favorites.item_id
|
||||
where items.active = true
|
||||
group by favorites.item_id
|
||||
group by favorites.item_id, items.slug
|
||||
having count(*) > 1
|
||||
order by favs desc
|
||||
limit 10
|
||||
@@ -110,7 +110,7 @@ export default (router, tpl) => {
|
||||
let xdtop = [];
|
||||
if (config.websrv.enable_xd_score) {
|
||||
const xdRows = await db`
|
||||
select id, xd_score
|
||||
select id, slug, xd_score
|
||||
from items
|
||||
where active = true and is_deleted = false and xd_score > 0
|
||||
order by xd_score desc
|
||||
|
||||
Reference in New Issue
Block a user