aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/activitypub
diff options
context:
space:
mode:
Diffstat (limited to 'shared/models/activitypub')
-rw-r--r--shared/models/activitypub/activity.ts10
-rw-r--r--shared/models/activitypub/objects/abuse-object.ts (renamed from shared/models/activitypub/objects/video-abuse-object.ts)4
-rw-r--r--shared/models/activitypub/objects/common-objects.ts4
-rw-r--r--shared/models/activitypub/objects/index.ts4
4 files changed, 12 insertions, 10 deletions
diff --git a/shared/models/activitypub/activity.ts b/shared/models/activitypub/activity.ts
index 31b9e4673..5b4ce214a 100644
--- a/shared/models/activitypub/activity.ts
+++ b/shared/models/activitypub/activity.ts
@@ -1,12 +1,12 @@
1import { ActivityPubActor } from './activitypub-actor' 1import { ActivityPubActor } from './activitypub-actor'
2import { ActivityPubSignature } from './activitypub-signature' 2import { ActivityPubSignature } from './activitypub-signature'
3import { CacheFileObject, VideoTorrentObject, ActivityFlagReasonObject } from './objects' 3import { ActivityFlagReasonObject, CacheFileObject, VideoTorrentObject } from './objects'
4import { AbuseObject } from './objects/abuse-object'
4import { DislikeObject } from './objects/dislike-object' 5import { DislikeObject } from './objects/dislike-object'
5import { VideoAbuseObject } from './objects/video-abuse-object'
6import { VideoCommentObject } from './objects/video-comment-object'
7import { ViewObject } from './objects/view-object'
8import { APObject } from './objects/object.model' 6import { APObject } from './objects/object.model'
9import { PlaylistObject } from './objects/playlist-object' 7import { PlaylistObject } from './objects/playlist-object'
8import { VideoCommentObject } from './objects/video-comment-object'
9import { ViewObject } from './objects/view-object'
10 10
11export type Activity = 11export type Activity =
12 ActivityCreate | 12 ActivityCreate |
@@ -53,7 +53,7 @@ export interface BaseActivity {
53 53
54export interface ActivityCreate extends BaseActivity { 54export interface ActivityCreate extends BaseActivity {
55 type: 'Create' 55 type: 'Create'
56 object: VideoTorrentObject | VideoAbuseObject | ViewObject | DislikeObject | VideoCommentObject | CacheFileObject | PlaylistObject 56 object: VideoTorrentObject | AbuseObject | ViewObject | DislikeObject | VideoCommentObject | CacheFileObject | PlaylistObject
57} 57}
58 58
59export interface ActivityUpdate extends BaseActivity { 59export interface ActivityUpdate extends BaseActivity {
diff --git a/shared/models/activitypub/objects/video-abuse-object.ts b/shared/models/activitypub/objects/abuse-object.ts
index 73add8ef4..ad45cc064 100644
--- a/shared/models/activitypub/objects/video-abuse-object.ts
+++ b/shared/models/activitypub/objects/abuse-object.ts
@@ -1,10 +1,12 @@
1import { ActivityFlagReasonObject } from './common-objects' 1import { ActivityFlagReasonObject } from './common-objects'
2 2
3export interface VideoAbuseObject { 3export interface AbuseObject {
4 type: 'Flag' 4 type: 'Flag'
5 content: string 5 content: string
6 object: string | string[] 6 object: string | string[]
7
7 tag?: ActivityFlagReasonObject[] 8 tag?: ActivityFlagReasonObject[]
9
8 startAt?: number 10 startAt?: number
9 endAt?: number 11 endAt?: number
10} 12}
diff --git a/shared/models/activitypub/objects/common-objects.ts b/shared/models/activitypub/objects/common-objects.ts
index 096d422ea..711ce45f4 100644
--- a/shared/models/activitypub/objects/common-objects.ts
+++ b/shared/models/activitypub/objects/common-objects.ts
@@ -1,4 +1,4 @@
1import { VideoAbusePredefinedReasonsString } from '@shared/models/videos' 1import { AbusePredefinedReasonsString } from '@shared/models'
2 2
3export interface ActivityIdentifierObject { 3export interface ActivityIdentifierObject {
4 identifier: string 4 identifier: string
@@ -85,7 +85,7 @@ export interface ActivityMentionObject {
85 85
86export interface ActivityFlagReasonObject { 86export interface ActivityFlagReasonObject {
87 type: 'Hashtag' 87 type: 'Hashtag'
88 name: VideoAbusePredefinedReasonsString 88 name: AbusePredefinedReasonsString
89} 89}
90 90
91export type ActivityTagObject = 91export type ActivityTagObject =
diff --git a/shared/models/activitypub/objects/index.ts b/shared/models/activitypub/objects/index.ts
index fba61e12f..a6a20e87a 100644
--- a/shared/models/activitypub/objects/index.ts
+++ b/shared/models/activitypub/objects/index.ts
@@ -1,6 +1,6 @@
1export * from './abuse-object'
1export * from './cache-file-object' 2export * from './cache-file-object'
2export * from './common-objects' 3export * from './common-objects'
3export * from './video-abuse-object' 4export * from './dislike-object'
4export * from './video-torrent-object' 5export * from './video-torrent-object'
5export * from './view-object' 6export * from './view-object'
6export * from './dislike-object'