aboutsummaryrefslogtreecommitdiffhomepage
path: root/server
diff options
context:
space:
mode:
Diffstat (limited to 'server')
-rw-r--r--server/models/user/user-video-history.ts9
1 files changed, 2 insertions, 7 deletions
diff --git a/server/models/user/user-video-history.ts b/server/models/user/user-video-history.ts
index 6d9f2e03f..8aff7b10c 100644
--- a/server/models/user/user-video-history.ts
+++ b/server/models/user/user-video-history.ts
@@ -57,19 +57,14 @@ export class UserVideoHistoryModel extends Model<Partial<AttributesOnly<UserVide
57 }) 57 })
58 User: UserModel 58 User: UserModel
59 59
60 static async listForApi (user: MUserAccountId, start: number, count: number, search?: string) { 60 static listForApi (user: MUserAccountId, start: number, count: number, search?: string) {
61 const serverActor = await getServerActor()
62
63 return VideoModel.listForApi({ 61 return VideoModel.listForApi({
64 start, 62 start,
65 count, 63 count,
66 search, 64 search,
67 sort: '-"userVideoHistory"."updatedAt"', 65 sort: '-"userVideoHistory"."updatedAt"',
68 nsfw: null, // All 66 nsfw: null, // All
69 displayOnlyForFollower: { 67 displayOnlyForFollower: null,
70 actorId: serverActor.id,
71 orLocalVideos: true
72 },
73 user, 68 user,
74 historyOfUser: user 69 historyOfUser: user
75 }) 70 })