diff options
Diffstat (limited to 'server/tests/fixtures/peertube-plugin-test-four/main.js')
-rw-r--r-- | server/tests/fixtures/peertube-plugin-test-four/main.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/server/tests/fixtures/peertube-plugin-test-four/main.js b/server/tests/fixtures/peertube-plugin-test-four/main.js index b9b207b81..bff42ff40 100644 --- a/server/tests/fixtures/peertube-plugin-test-four/main.js +++ b/server/tests/fixtures/peertube-plugin-test-four/main.js | |||
@@ -104,6 +104,20 @@ async function register ({ | |||
104 | isUser | 104 | isUser |
105 | }) | 105 | }) |
106 | }) | 106 | }) |
107 | |||
108 | router.get('/video-files/:id', async (req, res) => { | ||
109 | const details = await peertubeHelpers.videos.getFiles(req.params.id) | ||
110 | if (!details) return res.sendStatus(404) | ||
111 | |||
112 | return res.json(details) | ||
113 | }) | ||
114 | |||
115 | router.get('/ffprobe', async (req, res) => { | ||
116 | const result = await peertubeHelpers.videos.ffprobe(req.query.path) | ||
117 | if (!result) return res.sendStatus(404) | ||
118 | |||
119 | return res.json(result) | ||
120 | }) | ||
107 | } | 121 | } |
108 | 122 | ||
109 | } | 123 | } |