-import * as validator from 'validator'
+import validator from 'validator'
import { exists } from './misc'
import { CONSTRAINTS_FIELDS } from '../../initializers/constants'
import { VideoBlacklistType } from '../../../shared/models/videos'
}
function isVideoBlacklistTypeValid (value: any) {
- return exists(value) && validator.isInt('' + value) && VideoBlacklistType[value] !== undefined
+ return exists(value) &&
+ (value === VideoBlacklistType.AUTO_BEFORE_PUBLISHED || value === VideoBlacklistType.MANUAL)
}
// ---------------------------------------------------------------------------