mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-07 03:57:06 +03:00
Disable IP ratelimiting
This commit is contained in:
@@ -178,6 +178,8 @@ module.exports = async function postSkipSegments(req, res) {
|
||||
|
||||
let yesterday = timeSubmitted - 86400000;
|
||||
|
||||
// Disable IP ratelimiting for now
|
||||
if (false) {
|
||||
//check to see if this ip has submitted too many sponsors today
|
||||
let rateLimitCheckRow = privateDB.prepare("SELECT COUNT(*) as count FROM sponsorTimes WHERE hashedIP = ? AND videoID = ? AND timeSubmitted > ?").get([hashedIP, videoID, yesterday]);
|
||||
|
||||
@@ -187,6 +189,7 @@ module.exports = async function postSkipSegments(req, res) {
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
//check to see if the user has already submitted sponsors for this video
|
||||
let duplicateCheckRow = db.prepare("SELECT COUNT(*) as count FROM sponsorTimes WHERE userID = ? and videoID = ?").get([userID, videoID]);
|
||||
|
||||
Reference in New Issue
Block a user