aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/activitypub/client.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/controllers/activitypub/client.ts')
-rw-r--r--server/controllers/activitypub/client.ts23
1 files changed, 14 insertions, 9 deletions
diff --git a/server/controllers/activitypub/client.ts b/server/controllers/activitypub/client.ts
index c4e3cec6b..4e6bd5e25 100644
--- a/server/controllers/activitypub/client.ts
+++ b/server/controllers/activitypub/client.ts
@@ -20,7 +20,8 @@ import {
20 asyncMiddleware, 20 asyncMiddleware,
21 executeIfActivityPub, 21 executeIfActivityPub,
22 localAccountValidator, 22 localAccountValidator,
23 localVideoChannelValidator, 23 videoChannelsNameWithHostValidator,
24 ensureIsLocalChannel,
24 videosCustomGetValidator, 25 videosCustomGetValidator,
25 videosShareValidator 26 videosShareValidator
26} from '../../middlewares' 27} from '../../middlewares'
@@ -123,24 +124,28 @@ activityPubClientRouter.get('/videos/watch/:videoId/comments/:commentId/activity
123) 124)
124 125
125activityPubClientRouter.get( 126activityPubClientRouter.get(
126 [ '/video-channels/:name', '/video-channels/:name/videos', '/c/:name', '/c/:name/videos' ], 127 [ '/video-channels/:nameWithHost', '/video-channels/:nameWithHost/videos', '/c/:nameWithHost', '/c/:nameWithHost/videos' ],
127 executeIfActivityPub, 128 executeIfActivityPub,
128 asyncMiddleware(localVideoChannelValidator), 129 asyncMiddleware(videoChannelsNameWithHostValidator),
130 ensureIsLocalChannel,
129 videoChannelController 131 videoChannelController
130) 132)
131activityPubClientRouter.get('/video-channels/:name/followers', 133activityPubClientRouter.get('/video-channels/:nameWithHost/followers',
132 executeIfActivityPub, 134 executeIfActivityPub,
133 asyncMiddleware(localVideoChannelValidator), 135 asyncMiddleware(videoChannelsNameWithHostValidator),
136 ensureIsLocalChannel,
134 asyncMiddleware(videoChannelFollowersController) 137 asyncMiddleware(videoChannelFollowersController)
135) 138)
136activityPubClientRouter.get('/video-channels/:name/following', 139activityPubClientRouter.get('/video-channels/:nameWithHost/following',
137 executeIfActivityPub, 140 executeIfActivityPub,
138 asyncMiddleware(localVideoChannelValidator), 141 asyncMiddleware(videoChannelsNameWithHostValidator),
142 ensureIsLocalChannel,
139 asyncMiddleware(videoChannelFollowingController) 143 asyncMiddleware(videoChannelFollowingController)
140) 144)
141activityPubClientRouter.get('/video-channels/:name/playlists', 145activityPubClientRouter.get('/video-channels/:nameWithHost/playlists',
142 executeIfActivityPub, 146 executeIfActivityPub,
143 asyncMiddleware(localVideoChannelValidator), 147 asyncMiddleware(videoChannelsNameWithHostValidator),
148 ensureIsLocalChannel,
144 asyncMiddleware(videoChannelPlaylistsController) 149 asyncMiddleware(videoChannelPlaylistsController)
145) 150)
146 151