aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/middlewares/validators/videos
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-04-06 17:01:35 +0200
committerChocobozzz <chocobozzz@cpy.re>2021-04-08 10:07:53 +0200
commit2cb03dc1f4e01ba491c36caff30c33fe9c5bad89 (patch)
tree08a8706d105ea1e280339c02b9e2b1dc1edb0ff9 /server/middlewares/validators/videos
parentf479685678406a5df864d89615b33d29085ebfc6 (diff)
downloadPeerTube-2cb03dc1f4e01ba491c36caff30c33fe9c5bad89.tar.gz
PeerTube-2cb03dc1f4e01ba491c36caff30c33fe9c5bad89.tar.zst
PeerTube-2cb03dc1f4e01ba491c36caff30c33fe9c5bad89.zip
Add banners support
Diffstat (limited to 'server/middlewares/validators/videos')
-rw-r--r--server/middlewares/validators/videos/video-channels.ts2
1 files changed, 0 insertions, 2 deletions
diff --git a/server/middlewares/validators/videos/video-channels.ts b/server/middlewares/validators/videos/video-channels.ts
index 57ac548b9..2463d281c 100644
--- a/server/middlewares/validators/videos/video-channels.ts
+++ b/server/middlewares/validators/videos/video-channels.ts
@@ -73,13 +73,11 @@ const videoChannelsUpdateValidator = [
73 if (res.locals.videoChannel.Actor.isOwned() === false) { 73 if (res.locals.videoChannel.Actor.isOwned() === false) {
74 return res.status(HttpStatusCode.FORBIDDEN_403) 74 return res.status(HttpStatusCode.FORBIDDEN_403)
75 .json({ error: 'Cannot update video channel of another server' }) 75 .json({ error: 'Cannot update video channel of another server' })
76 .end()
77 } 76 }
78 77
79 if (res.locals.videoChannel.Account.userId !== res.locals.oauth.token.User.id) { 78 if (res.locals.videoChannel.Account.userId !== res.locals.oauth.token.User.id) {
80 return res.status(HttpStatusCode.FORBIDDEN_403) 79 return res.status(HttpStatusCode.FORBIDDEN_403)
81 .json({ error: 'Cannot update video channel of another user' }) 80 .json({ error: 'Cannot update video channel of another user' })
82 .end()
83 } 81 }
84 82
85 return next() 83 return next()