mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-09 13:07:02 +03:00
lint fix
This commit is contained in:
@@ -222,7 +222,7 @@ async function categoryVote(UUID: SegmentUUID, userID: UserID, isVIP: boolean, i
|
|||||||
[UUID], { useReplica: true })) as {category: Category, actionType: ActionType, videoID: VideoID, hashedVideoID: VideoIDHash, service: Service, userID: UserID, locked: number};
|
[UUID], { useReplica: true })) as {category: Category, actionType: ActionType, videoID: VideoID, hashedVideoID: VideoIDHash, service: Service, userID: UserID, locked: number};
|
||||||
|
|
||||||
if (!config.categorySupport[category]?.includes(segmentInfo.actionType) || segmentInfo.actionType === ActionType.Full) {
|
if (!config.categorySupport[category]?.includes(segmentInfo.actionType) || segmentInfo.actionType === ActionType.Full) {
|
||||||
return { status: 400, message: `Not allowed to change to ${category} when for segment of type ${segmentInfo.actionType}`};
|
return { status: 400, message: `Not allowed to change to ${category} when for segment of type ${segmentInfo.actionType}` };
|
||||||
}
|
}
|
||||||
if (!config.categoryList.includes(category)) {
|
if (!config.categoryList.includes(category)) {
|
||||||
return { status: 400, message: "Category doesn't exist." };
|
return { status: 400, message: "Category doesn't exist." };
|
||||||
|
|||||||
@@ -17,6 +17,6 @@ const subCode = (length = 8) => {
|
|||||||
result += characters[(Math.floor(Math.random() * characters.length))];
|
result += characters[(Math.floor(Math.random() * characters.length))];
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
};
|
||||||
|
|
||||||
export const generateLicense = (): string => `${subCode()}-${subCode()}-${subCode()}-${subCode()}`;
|
export const generateLicense = (): string => `${subCode()}-${subCode()}-${subCode()}-${subCode()}`;
|
||||||
|
|||||||
Reference in New Issue
Block a user