Skip to content

Commit 4f7f6c7

Browse files
committed
Whoops
1 parent 6afab4f commit 4f7f6c7

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

services/leaderboard.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ const helper = require('../helper');
33
const config = require('../config');
44

55
const sql = `SELECT nickname, COUNT(DISTINCT videoId) AS video_count FROM user_video
6-
INNER JOIN ircbot.user ON ircbot.user_video.userId = ircbot.user.userId GROUP BY user_video.userId
6+
INNER JOIN user ON user_video.userId = user.userId GROUP BY user_video.userId
77
ORDER BY video_count DESC LIMIT ?,?`;
88

99
async function get(page = 1){

services/users.js

+1-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ async function getMultiple(page = 1){
1010
[offset, config.listPerPage]
1111
);
1212
const total = await db.query(
13-
`SELECT COUNT(*) AS numRows FROM user`,
14-
[userid]
13+
`SELECT COUNT(*) AS numRows FROM user`
1514
);
1615
const data = helper.emptyOrRows(rows);
1716
const perPage = config.listPerPage;

0 commit comments

Comments
 (0)