mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-16 08:26:59 +03:00
Don't remove all warnings
This commit is contained in:
@@ -25,7 +25,7 @@ export function postWarning(req: Request, res: Response) {
|
|||||||
db.prepare('run', 'INSERT INTO warnings (userID, issueTime, issuerUserID, enabled) VALUES (?, ?, ?, 1)', [userID, issueTime, issuerUserID]);
|
db.prepare('run', 'INSERT INTO warnings (userID, issueTime, issuerUserID, enabled) VALUES (?, ?, ?, 1)', [userID, issueTime, issuerUserID]);
|
||||||
resultStatus = "issued to";
|
resultStatus = "issued to";
|
||||||
} else {
|
} else {
|
||||||
db.prepare('run', 'UPDATE warnings SET enabled = 0', []);
|
db.prepare('run', 'UPDATE warnings SET enabled = 0 WHERE userID = ? AND issuerUserID = ?', [userID, issuerUserID]);
|
||||||
resultStatus = "removed from";
|
resultStatus = "removed from";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user