aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib/webtorrentProcess.js
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2016-05-11 21:19:34 +0200
committerChocobozzz <florian.bigard@gmail.com>2016-05-13 14:23:11 +0200
commitbc503c2a62dcf9aed6b8d90b68f0f27a7755ac01 (patch)
treea1fe1ad88afd29ee4d7cb05c480649d5a9c6f9a0 /server/lib/webtorrentProcess.js
parent881a5e68b64e4acd43408852bbdc914643d8fac6 (diff)
downloadPeerTube-bc503c2a62dcf9aed6b8d90b68f0f27a7755ac01.tar.gz
PeerTube-bc503c2a62dcf9aed6b8d90b68f0f27a7755ac01.tar.zst
PeerTube-bc503c2a62dcf9aed6b8d90b68f0f27a7755ac01.zip
Update to standard 7. Goodbye snake_case, I used to love you
Diffstat (limited to 'server/lib/webtorrentProcess.js')
-rw-r--r--server/lib/webtorrentProcess.js14
1 files changed, 7 insertions, 7 deletions
diff --git a/server/lib/webtorrentProcess.js b/server/lib/webtorrentProcess.js
index 7889e7128..be7ac5bb4 100644
--- a/server/lib/webtorrentProcess.js
+++ b/server/lib/webtorrentProcess.js
@@ -26,11 +26,11 @@ function webtorrent (args) {
26 const _id = data._id 26 const _id = data._id
27 27
28 wt.seed(path, { announceList: '' }, function (torrent) { 28 wt.seed(path, { announceList: '' }, function (torrent) {
29 const to_send = { 29 const toSend = {
30 magnetUri: torrent.magnetURI 30 magnetUri: torrent.magnetURI
31 } 31 }
32 32
33 ipc.of[nodeKey].emit(nodeKey + '.seedDone.' + _id, to_send) 33 ipc.of[nodeKey].emit(nodeKey + '.seedDone.' + _id, toSend)
34 }) 34 })
35 } 35 }
36 36
@@ -40,15 +40,15 @@ function webtorrent (args) {
40 const _id = data._id 40 const _id = data._id
41 41
42 wt.add(magnetUri, function (torrent) { 42 wt.add(magnetUri, function (torrent) {
43 const to_send = { 43 const toSend = {
44 files: [] 44 files: []
45 } 45 }
46 46
47 torrent.files.forEach(function (file) { 47 torrent.files.forEach(function (file) {
48 to_send.files.push({ path: file.path }) 48 toSend.files.push({ path: file.path })
49 }) 49 })
50 50
51 ipc.of[nodeKey].emit(nodeKey + '.addDone.' + _id, to_send) 51 ipc.of[nodeKey].emit(nodeKey + '.addDone.' + _id, toSend)
52 }) 52 })
53 } 53 }
54 54
@@ -65,8 +65,8 @@ function webtorrent (args) {
65 } 65 }
66 66
67 function callback () { 67 function callback () {
68 const to_send = {} 68 const toSend = {}
69 ipc.of[nodeKey].emit(nodeKey + '.removeDone.' + _id, to_send) 69 ipc.of[nodeKey].emit(nodeKey + '.removeDone.' + _id, toSend)
70 } 70 }
71 } 71 }
72 72