From 2c8776fc316da9719e5ebc55dfabdcac9e197ac4 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 4 Feb 2020 16:14:33 +0100 Subject: Optimize view endpoint --- server/controllers/activitypub/client.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'server/controllers/activitypub') diff --git a/server/controllers/activitypub/client.ts b/server/controllers/activitypub/client.ts index 9a5fd6084..395cfa0d5 100644 --- a/server/controllers/activitypub/client.ts +++ b/server/controllers/activitypub/client.ts @@ -1,4 +1,3 @@ -// Intercept ActivityPub client requests import * as express from 'express' import { VideoPrivacy, VideoRateType } from '../../../shared/models/videos' import { activityPubCollectionPagination, activityPubContextify } from '../../helpers/activitypub' @@ -37,10 +36,12 @@ import { buildDislikeActivity } from '../../lib/activitypub/send/send-dislike' import { videoPlaylistElementAPGetValidator, videoPlaylistsGetValidator } from '../../middlewares/validators/videos/video-playlists' import { VideoPlaylistModel } from '../../models/video/video-playlist' import { VideoPlaylistPrivacy } from '../../../shared/models/videos/playlist/video-playlist-privacy.model' -import { MAccountId, MActorId, MVideo, MVideoAPWithoutCaption, MVideoId } from '@server/typings/models' +import { MAccountId, MActorId, MVideoAPWithoutCaption, MVideoId } from '@server/typings/models' const activityPubClientRouter = express.Router() +// Intercept ActivityPub client requests + activityPubClientRouter.get('/accounts?/:name', executeIfActivityPub, asyncMiddleware(localAccountValidator), -- cgit v1.2.3