mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-06 11:36:58 +03:00
Add seperate type for dearrow warning
Also add dearrow warning reason as option for user info
This commit is contained in:
@@ -7,7 +7,7 @@ import { client } from "../utils/httpClient";
|
||||
describe("postWarning", () => {
|
||||
// constants
|
||||
const endpoint = "/api/warnUser";
|
||||
const getWarning = (userID: string) => db.prepare("get", `SELECT "userID", "issueTime", "issuerUserID", enabled, "reason" FROM warnings WHERE "userID" = ?`, [userID]);
|
||||
const getWarning = (userID: string, type = 0) => db.prepare("get", `SELECT "userID", "issueTime", "issuerUserID", enabled, "reason" FROM warnings WHERE "userID" = ? AND "type" = ?`, [userID, type]);
|
||||
|
||||
const warneduserID = "warning-0";
|
||||
const warnedUserPublicID = getHash(warneduserID);
|
||||
|
||||
Reference in New Issue
Block a user