diff options
Diffstat (limited to 'server/helpers/custom-validators/videos.ts')
-rw-r--r-- | server/helpers/custom-validators/videos.ts | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/server/helpers/custom-validators/videos.ts b/server/helpers/custom-validators/videos.ts index 8ef3a3c64..a46d715ba 100644 --- a/server/helpers/custom-validators/videos.ts +++ b/server/helpers/custom-validators/videos.ts | |||
@@ -42,6 +42,10 @@ function isVideoDescriptionValid (value: string) { | |||
42 | return value === null || (exists(value) && validator.isLength(value, VIDEOS_CONSTRAINTS_FIELDS.DESCRIPTION)) | 42 | return value === null || (exists(value) && validator.isLength(value, VIDEOS_CONSTRAINTS_FIELDS.DESCRIPTION)) |
43 | } | 43 | } |
44 | 44 | ||
45 | function isVideoSupportValid (value: string) { | ||
46 | return value === null || (exists(value) && validator.isLength(value, VIDEOS_CONSTRAINTS_FIELDS.SUPPORT)) | ||
47 | } | ||
48 | |||
45 | function isVideoNameValid (value: string) { | 49 | function isVideoNameValid (value: string) { |
46 | return exists(value) && validator.isLength(value, VIDEOS_CONSTRAINTS_FIELDS.NAME) | 50 | return exists(value) && validator.isLength(value, VIDEOS_CONSTRAINTS_FIELDS.NAME) |
47 | } | 51 | } |
@@ -140,5 +144,6 @@ export { | |||
140 | isVideoFileResolutionValid, | 144 | isVideoFileResolutionValid, |
141 | isVideoFileSizeValid, | 145 | isVideoFileSizeValid, |
142 | isVideoExist, | 146 | isVideoExist, |
143 | isVideoImage | 147 | isVideoImage, |
148 | isVideoSupportValid | ||
144 | } | 149 | } |