aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/api/v1/remoteVideos.js
diff options
context:
space:
mode:
Diffstat (limited to 'server/controllers/api/v1/remoteVideos.js')
-rw-r--r--server/controllers/api/v1/remoteVideos.js20
1 files changed, 10 insertions, 10 deletions
diff --git a/server/controllers/api/v1/remoteVideos.js b/server/controllers/api/v1/remoteVideos.js
index 7622e39f5..58222de52 100644
--- a/server/controllers/api/v1/remoteVideos.js
+++ b/server/controllers/api/v1/remoteVideos.js
@@ -1,15 +1,15 @@
1'use strict' 1'use strict'
2 2
3var express = require('express') 3const express = require('express')
4var pluck = require('lodash-node/compat/collection/pluck') 4const pluck = require('lodash-node/compat/collection/pluck')
5 5
6var middleware = require('../../../middlewares') 6const middleware = require('../../../middlewares')
7var secureMiddleware = middleware.secure 7const secureMiddleware = middleware.secure
8var cacheMiddleware = middleware.cache 8const cacheMiddleware = middleware.cache
9var reqValidator = middleware.reqValidators.remote 9const reqValidator = middleware.reqValidators.remote
10var videos = require('../../../models/videos') 10const videos = require('../../../models/videos')
11 11
12var router = express.Router() 12const router = express.Router()
13 13
14router.post('/add', 14router.post('/add',
15 reqValidator.secureRequest, 15 reqValidator.secureRequest,
@@ -42,8 +42,8 @@ function addRemoteVideos (req, res, next) {
42} 42}
43 43
44function removeRemoteVideo (req, res, next) { 44function removeRemoteVideo (req, res, next) {
45 var url = req.body.signature.url 45 const url = req.body.signature.url
46 var magnetUris = pluck(req.body.data, 'magnetUri') 46 const magnetUris = pluck(req.body.data, 'magnetUri')
47 47
48 videos.removeRemotesOfByMagnetUris(url, magnetUris, function (err) { 48 videos.removeRemotesOfByMagnetUris(url, magnetUris, function (err) {
49 if (err) return next(err) 49 if (err) return next(err)