]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/middlewares/validators/videos/video-view.ts
Translated using Weblate (Persian)
[github/Chocobozzz/PeerTube.git] / server / middlewares / validators / videos / video-view.ts
index 4927c04ad65b706501b436aedafdb2998e2cfc95..6e2d4505d9bab43ef4dda175e9d7650a0d1a1c2f 100644 (file)
@@ -1,20 +1,17 @@
 import express from 'express'
 import { body, param } from 'express-validator'
 import { isVideoTimeValid } from '@server/helpers/custom-validators/video-view'
+import { getCachedVideoDuration } from '@server/lib/video'
 import { LocalVideoViewerModel } from '@server/models/view/local-video-viewer'
 import { HttpStatusCode } from '../../../../shared/models/http/http-error-codes'
 import { exists, isIdValid, isIntOrNull, toIntOrNull } from '../../../helpers/custom-validators/misc'
-import { logger } from '../../../helpers/logger'
 import { areValidationErrors, doesVideoExist, isValidVideoIdParam } from '../shared'
-import { getCachedVideoDuration } from '@server/lib/video'
 
 const getVideoLocalViewerValidator = [
   param('localViewerId')
     .custom(isIdValid),
 
   async (req: express.Request, res: express.Response, next: express.NextFunction) => {
-    logger.debug('Checking getVideoLocalViewerValidator parameters', { parameters: req.params })
-
     if (areValidationErrors(req, res)) return
 
     const localViewer = await LocalVideoViewerModel.loadFullById(+req.params.localViewerId)
@@ -40,8 +37,6 @@ const videoViewValidator = [
     .custom(isIntOrNull),
 
   async (req: express.Request, res: express.Response, next: express.NextFunction) => {
-    logger.debug('Checking videoView parameters', { parameters: req.body })
-
     if (areValidationErrors(req, res)) return
     if (!await doesVideoExist(req.params.videoId, res, 'only-immutable-attributes')) return