mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-06 19:47:00 +03:00
Merge pull request #160 from ajayyy/experimental
Fix example error codes
This commit is contained in:
@@ -28,7 +28,7 @@
|
||||
"windowMs": 900000, // 15 minutes
|
||||
"max": 20, // 20 requests in 15min time window
|
||||
"message": "Too many votes, please try again later",
|
||||
"statusCode": 200
|
||||
"statusCode": 429
|
||||
},
|
||||
"view": {
|
||||
"windowMs": 900000, // 15 minutes
|
||||
|
||||
@@ -38,7 +38,7 @@ var oldSubmitSponsorTimes = require('./routes/oldSubmitSponsorTimes.js');
|
||||
let voteEndpoints = [voteOnSponsorTime.endpoint];
|
||||
let viewEndpoints = [viewedVideoSponsorTime];
|
||||
if (config.rateLimit) {
|
||||
// if (config.rateLimit.vote) voteEndpoints.unshift(rateLimitMiddleware(config.rateLimit.vote));
|
||||
if (config.rateLimit.vote) voteEndpoints.unshift(rateLimitMiddleware(config.rateLimit.vote));
|
||||
if (config.rateLimit.view) viewEndpoints.unshift(rateLimitMiddleware(config.rateLimit.view));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user