mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 10:49:28 +02:00
OAuth/User models refractoring -> use mongoose api
This commit is contained in:
parent
a3ee6fa22d
commit
69b0a27cbb
14 changed files with 217 additions and 156 deletions
|
@ -9,7 +9,7 @@ const multer = require('multer')
|
|||
const logger = require('../../../helpers/logger')
|
||||
const friends = require('../../../lib/friends')
|
||||
const middlewares = require('../../../middlewares')
|
||||
const oAuth2 = middlewares.oauth2
|
||||
const oAuth = middlewares.oauth
|
||||
const pagination = middlewares.pagination
|
||||
const reqValidator = middlewares.reqValidators
|
||||
const reqValidatorPagination = reqValidator.pagination
|
||||
|
@ -51,7 +51,7 @@ router.get('/',
|
|||
listVideos
|
||||
)
|
||||
router.post('/',
|
||||
oAuth2.authenticate,
|
||||
oAuth.authenticate,
|
||||
reqFiles,
|
||||
reqValidatorVideos.videosAdd,
|
||||
addVideo
|
||||
|
@ -61,7 +61,7 @@ router.get('/:id',
|
|||
getVideo
|
||||
)
|
||||
router.delete('/:id',
|
||||
oAuth2.authenticate,
|
||||
oAuth.authenticate,
|
||||
reqValidatorVideos.videosRemove,
|
||||
removeVideo
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue