mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2024-11-10 01:02:30 +01:00
Raised stats limit to 100.
This commit is contained in:
parent
db1a3a4062
commit
69258587bc
1 changed files with 1 additions and 1 deletions
2
index.js
2
index.js
|
@ -374,7 +374,7 @@ app.get('/api/getTopUsers', function (req, res) {
|
||||||
let totalSubmissions = [];
|
let totalSubmissions = [];
|
||||||
let minutesSaved = [];
|
let minutesSaved = [];
|
||||||
|
|
||||||
db.prepare("SELECT sponsorTimes.userID as userID, COUNT(*) as totalSubmissions, SUM(views) as viewCount, SUM((sponsorTimes.endTime - sponsorTimes.startTime) / 60 * sponsorTimes.views) as minutesSaved, userNames.userName as userName FROM sponsorTimes LEFT JOIN userNames ON sponsorTimes.userID=userNames.userID WHERE sponsorTimes.votes > -1 GROUP BY sponsorTimes.userID ORDER BY " + sortBy + " DESC LIMIT 50").all(function(err, rows) {
|
db.prepare("SELECT sponsorTimes.userID as userID, COUNT(*) as totalSubmissions, SUM(views) as viewCount, SUM((sponsorTimes.endTime - sponsorTimes.startTime) / 60 * sponsorTimes.views) as minutesSaved, userNames.userName as userName FROM sponsorTimes LEFT JOIN userNames ON sponsorTimes.userID=userNames.userID WHERE sponsorTimes.votes > -1 GROUP BY sponsorTimes.userID ORDER BY " + sortBy + " DESC LIMIT 100").all(function(err, rows) {
|
||||||
for (let i = 0; i < rows.length; i++) {
|
for (let i = 0; i < rows.length; i++) {
|
||||||
if (rows[i].userName != null) {
|
if (rows[i].userName != null) {
|
||||||
userNames[i] = rows[i].userName;
|
userNames[i] = rows[i].userName;
|
||||||
|
|
Loading…
Reference in a new issue