mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-08 20:47:02 +03:00
Removed banned users from total stats.
This commit is contained in:
2
index.js
2
index.js
@@ -651,7 +651,7 @@ app.get('/api/getTopUsers', function (req, res) {
|
||||
//send out totals
|
||||
//send the total submissions, total views and total minutes saved
|
||||
app.get('/api/getTotalStats', function (req, res) {
|
||||
db.prepare("SELECT COUNT(DISTINCT userID) as userCount, COUNT(*) as totalSubmissions, SUM(views) as viewCount, SUM((endTime - startTime) / 60 * views) as minutesSaved FROM sponsorTimes").get(function(err, row) {
|
||||
db.prepare("SELECT COUNT(DISTINCT userID) as userCount, COUNT(*) as totalSubmissions, SUM(views) as viewCount, SUM((endTime - startTime) / 60 * views) as minutesSaved FROM sponsorTimes WHERE shadowHidden != 1").get(function(err, row) {
|
||||
if (row != null) {
|
||||
//send this result
|
||||
res.send({
|
||||
|
||||
Reference in New Issue
Block a user