diff options
author | Chocobozzz <me@florianbigard.com> | 2022-09-07 17:18:29 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2022-09-08 08:41:48 +0200 |
commit | d4d9bbc6f24522f5d63b0ab105a02f80ca98d702 (patch) | |
tree | 9e7e5e5170cea36a489f6c988df892a34c886937 /server/controllers/api/video-channel-sync.ts | |
parent | 8b69f9f02879ee3cf72bc9d4aa96cc71f18e6eea (diff) | |
download | PeerTube-d4d9bbc6f24522f5d63b0ab105a02f80ca98d702.tar.gz PeerTube-d4d9bbc6f24522f5d63b0ab105a02f80ca98d702.tar.zst PeerTube-d4d9bbc6f24522f5d63b0ab105a02f80ca98d702.zip |
Fix channel sync right check
Diffstat (limited to 'server/controllers/api/video-channel-sync.ts')
-rw-r--r-- | server/controllers/api/video-channel-sync.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/server/controllers/api/video-channel-sync.ts b/server/controllers/api/video-channel-sync.ts index c2770b8e4..03c54b59c 100644 --- a/server/controllers/api/video-channel-sync.ts +++ b/server/controllers/api/video-channel-sync.ts | |||
@@ -5,7 +5,7 @@ import { | |||
5 | asyncMiddleware, | 5 | asyncMiddleware, |
6 | asyncRetryTransactionMiddleware, | 6 | asyncRetryTransactionMiddleware, |
7 | authenticate, | 7 | authenticate, |
8 | ensureCanManageChannel as ensureCanManageSyncedChannel, | 8 | ensureCanManageChannelOrAccount, |
9 | ensureSyncExists, | 9 | ensureSyncExists, |
10 | ensureSyncIsEnabled, | 10 | ensureSyncIsEnabled, |
11 | videoChannelSyncValidator | 11 | videoChannelSyncValidator |
@@ -21,14 +21,14 @@ videoChannelSyncRouter.post('/', | |||
21 | authenticate, | 21 | authenticate, |
22 | ensureSyncIsEnabled, | 22 | ensureSyncIsEnabled, |
23 | asyncMiddleware(videoChannelSyncValidator), | 23 | asyncMiddleware(videoChannelSyncValidator), |
24 | ensureCanManageSyncedChannel, | 24 | ensureCanManageChannelOrAccount, |
25 | asyncRetryTransactionMiddleware(createVideoChannelSync) | 25 | asyncRetryTransactionMiddleware(createVideoChannelSync) |
26 | ) | 26 | ) |
27 | 27 | ||
28 | videoChannelSyncRouter.delete('/:id', | 28 | videoChannelSyncRouter.delete('/:id', |
29 | authenticate, | 29 | authenticate, |
30 | asyncMiddleware(ensureSyncExists), | 30 | asyncMiddleware(ensureSyncExists), |
31 | ensureCanManageSyncedChannel, | 31 | ensureCanManageChannelOrAccount, |
32 | asyncRetryTransactionMiddleware(removeVideoChannelSync) | 32 | asyncRetryTransactionMiddleware(removeVideoChannelSync) |
33 | ) | 33 | ) |
34 | 34 | ||