mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-24 16:38:41 +03:00
Fix duplicate behavior with submitting full video labels
This commit is contained in:
@@ -329,13 +329,12 @@ async function checkEachSegmentValid(rawIP: IPAddress, paramUserID: UserID, user
|
||||
if (segments[i].actionType === ActionType.Full) {
|
||||
// Forward as vote
|
||||
await vote(rawIP, duplicateCheck2Row.UUID, paramUserID, 1);
|
||||
segments[i].ignoreSegment = true;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (segments.every((s) => s.ignoreSegment)) {
|
||||
if (segments.every((s) => s.ignoreSegment && s.actionType !== ActionType.Full)) {
|
||||
return { pass: false, errorMessage: "Segment has already been submitted before.", errorCode: 409 };
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user