X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Fmiddlewares%2Fvalidators%2Fvideos%2Fvideo-shares.ts;h=6f4a1f3e064f311c27bec5749bdee6ef26fa6cd3;hb=3e753302d8c911b59971c16a8018df0e1ab78465;hp=d5cbdb03ef2ae64eccfdc821f6d844e4bbc03a79;hpb=a8b666e9f1ed002230869606308749614390c82f;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/middlewares/validators/videos/video-shares.ts b/server/middlewares/validators/videos/video-shares.ts index d5cbdb03e..6f4a1f3e0 100644 --- a/server/middlewares/validators/videos/video-shares.ts +++ b/server/middlewares/validators/videos/video-shares.ts @@ -2,10 +2,10 @@ import * as express from 'express' import 'express-validator' import { param } from 'express-validator/check' import { isIdOrUUIDValid, isIdValid } from '../../../helpers/custom-validators/misc' -import { doesVideoExist } from '../../../helpers/custom-validators/videos' import { logger } from '../../../helpers/logger' import { VideoShareModel } from '../../../models/video/video-share' import { areValidationErrors } from '../utils' +import { doesVideoExist } from '../../../helpers/middlewares' const videosShareValidator = [ param('id').custom(isIdOrUUIDValid).not().isEmpty().withMessage('Should have a valid id'),