Allow VIP to submit poi segments at any time

This commit is contained in:
Ajay Ramachandran 2021-08-31 12:27:15 -04:00
parent df904e3744
commit ba7fb6525f

View file

@ -390,8 +390,8 @@ async function checkEachSegmentValid(userID: string, videoID: VideoID
return { pass: false, errorMessage: "One of your segments times are invalid (too short, startTime before endTime, etc.)", errorCode: 400};
}
// Check for POI segments before 1 second
if (getCategoryActionType(segments[i].category) === CategoryActionType.POI && startTime < config.poiMinimumStartTime) {
// Check for POI segments before some seconds
if (!isVIP && getCategoryActionType(segments[i].category) === CategoryActionType.POI && startTime < config.poiMinimumStartTime) {
return { pass: false, errorMessage: `POI cannot be that early`, errorCode: 400};
}