aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/middlewares/validators/pods.ts
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2017-09-14 17:06:31 +0200
committerChocobozzz <florian.bigard@gmail.com>2017-09-14 17:25:36 +0200
commitbfb3a98fac582f104c6d9b8b7242ea2cbb650b91 (patch)
tree24ead7cbbdc785315c406dfba85a55fe5e235d09 /server/middlewares/validators/pods.ts
parentd5050d1e097e761685fbaafe6e3d4b8b78d48356 (diff)
downloadPeerTube-bfb3a98fac582f104c6d9b8b7242ea2cbb650b91.tar.gz
PeerTube-bfb3a98fac582f104c6d9b8b7242ea2cbb650b91.tar.zst
PeerTube-bfb3a98fac582f104c6d9b8b7242ea2cbb650b91.zip
Remove ng2 file upload module
Unmaintained and we don't need it anymore with httpclient
Diffstat (limited to 'server/middlewares/validators/pods.ts')
-rw-r--r--server/middlewares/validators/pods.ts6
1 files changed, 5 insertions, 1 deletions
diff --git a/server/middlewares/validators/pods.ts b/server/middlewares/validators/pods.ts
index 4d0e054b0..3a0f56f6a 100644
--- a/server/middlewares/validators/pods.ts
+++ b/server/middlewares/validators/pods.ts
@@ -11,7 +11,11 @@ import { isTestInstance } from '../../helpers'
11function makeFriendsValidator (req: express.Request, res: express.Response, next: express.NextFunction) { 11function makeFriendsValidator (req: express.Request, res: express.Response, next: express.NextFunction) {
12 // Force https if the administrator wants to make friends 12 // Force https if the administrator wants to make friends
13 if (isTestInstance() === false && CONFIG.WEBSERVER.SCHEME === 'http') { 13 if (isTestInstance() === false && CONFIG.WEBSERVER.SCHEME === 'http') {
14 return res.status(400).send('Cannot make friends with a non HTTPS web server.') 14 return res.status(400)
15 .json({
16 error: 'Cannot make friends with a non HTTPS web server.'
17 })
18 .end()
15 } 19 }
16 20
17 req.checkBody('hosts', 'Should have an array of unique hosts').isEachUniqueHostValid() 21 req.checkBody('hosts', 'Should have an array of unique hosts').isEachUniqueHostValid()