]>
Commit | Line | Data |
---|---|---|
55fa55a9 C |
1 | 'use strict' |
2 | ||
3 | const checkErrors = require('../utils').checkErrors | |
4 | const logger = require('../../../helpers/logger') | |
5 | ||
6 | const validatorsRemoteVideos = { | |
9e167724 | 7 | remoteVideos, |
e4c87ec2 C |
8 | remoteQaduVideos, |
9 | remoteEventsVideos | |
55fa55a9 C |
10 | } |
11 | ||
12 | function remoteVideos (req, res, next) { | |
13 | req.checkBody('data').isEachRemoteRequestVideosValid() | |
14 | ||
15 | logger.debug('Checking remoteVideos parameters', { parameters: req.body }) | |
16 | ||
17 | checkErrors(req, res, next) | |
18 | } | |
19 | ||
9e167724 C |
20 | function remoteQaduVideos (req, res, next) { |
21 | req.checkBody('data').isEachRemoteRequestVideosQaduValid() | |
22 | ||
e4c87ec2 | 23 | logger.debug('Checking remoteQaduVideos parameters', { parameters: req.body }) |
9e167724 C |
24 | |
25 | checkErrors(req, res, next) | |
26 | } | |
27 | ||
e4c87ec2 C |
28 | function remoteEventsVideos (req, res, next) { |
29 | req.checkBody('data').isEachRemoteRequestVideosEventsValid() | |
30 | ||
31 | logger.debug('Checking remoteEventsVideos parameters', { parameters: req.body }) | |
32 | ||
33 | checkErrors(req, res, next) | |
34 | } | |
55fa55a9 C |
35 | // --------------------------------------------------------------------------- |
36 | ||
37 | module.exports = validatorsRemoteVideos |