diff options
Diffstat (limited to 'server/controllers/activitypub/outbox.ts')
-rw-r--r-- | server/controllers/activitypub/outbox.ts | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/server/controllers/activitypub/outbox.ts b/server/controllers/activitypub/outbox.ts index 4175cf276..8c88b6971 100644 --- a/server/controllers/activitypub/outbox.ts +++ b/server/controllers/activitypub/outbox.ts | |||
@@ -7,7 +7,13 @@ import { VideoPrivacy } from '../../../shared/models/videos' | |||
7 | import { logger } from '../../helpers/logger' | 7 | import { logger } from '../../helpers/logger' |
8 | import { buildAudience } from '../../lib/activitypub/audience' | 8 | import { buildAudience } from '../../lib/activitypub/audience' |
9 | import { buildAnnounceActivity, buildCreateActivity } from '../../lib/activitypub/send' | 9 | import { buildAnnounceActivity, buildCreateActivity } from '../../lib/activitypub/send' |
10 | import { asyncMiddleware, ensureIsLocalChannel, localAccountValidator, videoChannelsNameWithHostValidator } from '../../middlewares' | 10 | import { |
11 | activityPubRateLimiter, | ||
12 | asyncMiddleware, | ||
13 | ensureIsLocalChannel, | ||
14 | localAccountValidator, | ||
15 | videoChannelsNameWithHostValidator | ||
16 | } from '../../middlewares' | ||
11 | import { apPaginationValidator } from '../../middlewares/validators/activitypub' | 17 | import { apPaginationValidator } from '../../middlewares/validators/activitypub' |
12 | import { VideoModel } from '../../models/video/video' | 18 | import { VideoModel } from '../../models/video/video' |
13 | import { activityPubResponse } from './utils' | 19 | import { activityPubResponse } from './utils' |
@@ -15,12 +21,14 @@ import { activityPubResponse } from './utils' | |||
15 | const outboxRouter = express.Router() | 21 | const outboxRouter = express.Router() |
16 | 22 | ||
17 | outboxRouter.get('/accounts/:name/outbox', | 23 | outboxRouter.get('/accounts/:name/outbox', |
24 | activityPubRateLimiter, | ||
18 | apPaginationValidator, | 25 | apPaginationValidator, |
19 | localAccountValidator, | 26 | localAccountValidator, |
20 | asyncMiddleware(outboxController) | 27 | asyncMiddleware(outboxController) |
21 | ) | 28 | ) |
22 | 29 | ||
23 | outboxRouter.get('/video-channels/:nameWithHost/outbox', | 30 | outboxRouter.get('/video-channels/:nameWithHost/outbox', |
31 | activityPubRateLimiter, | ||
24 | apPaginationValidator, | 32 | apPaginationValidator, |
25 | asyncMiddleware(videoChannelsNameWithHostValidator), | 33 | asyncMiddleware(videoChannelsNameWithHostValidator), |
26 | ensureIsLocalChannel, | 34 | ensureIsLocalChannel, |