aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models
diff options
context:
space:
mode:
Diffstat (limited to 'shared/models')
-rw-r--r--shared/models/activitypub/activity.ts8
-rw-r--r--shared/models/activitypub/objects/index.ts1
-rw-r--r--shared/models/activitypub/objects/video-abuse-object.ts5
-rw-r--r--shared/models/activitypub/objects/video-channel-object.ts2
-rw-r--r--shared/models/videos/video-abuse.model.ts4
5 files changed, 12 insertions, 8 deletions
diff --git a/shared/models/activitypub/activity.ts b/shared/models/activitypub/activity.ts
index 254daf118..506e64eff 100644
--- a/shared/models/activitypub/activity.ts
+++ b/shared/models/activitypub/activity.ts
@@ -1,8 +1,6 @@
1import { 1import { VideoChannelObject, VideoTorrentObject } from './objects'
2 VideoChannelObject,
3 VideoTorrentObject
4} from './objects'
5import { ActivityPubSignature } from './activitypub-signature' 2import { ActivityPubSignature } from './activitypub-signature'
3import { VideoAbuseObject } from './objects/video-abuse-object'
6 4
7export type Activity = ActivityCreate | ActivityAdd | ActivityUpdate | ActivityFlag | 5export type Activity = ActivityCreate | ActivityAdd | ActivityUpdate | ActivityFlag |
8 ActivityDelete | ActivityFollow | ActivityAccept 6 ActivityDelete | ActivityFollow | ActivityAccept
@@ -21,7 +19,7 @@ export interface BaseActivity {
21 19
22export interface ActivityCreate extends BaseActivity { 20export interface ActivityCreate extends BaseActivity {
23 type: 'Create' 21 type: 'Create'
24 object: VideoChannelObject 22 object: VideoChannelObject | VideoAbuseObject
25} 23}
26 24
27export interface ActivityAdd extends BaseActivity { 25export interface ActivityAdd extends BaseActivity {
diff --git a/shared/models/activitypub/objects/index.ts b/shared/models/activitypub/objects/index.ts
index 8c2e2daca..cd772b28d 100644
--- a/shared/models/activitypub/objects/index.ts
+++ b/shared/models/activitypub/objects/index.ts
@@ -1,3 +1,4 @@
1export * from './common-objects' 1export * from './common-objects'
2export * from './video-abuse-object'
2export * from './video-channel-object' 3export * from './video-channel-object'
3export * from './video-torrent-object' 4export * from './video-torrent-object'
diff --git a/shared/models/activitypub/objects/video-abuse-object.ts b/shared/models/activitypub/objects/video-abuse-object.ts
new file mode 100644
index 000000000..40e7abd57
--- /dev/null
+++ b/shared/models/activitypub/objects/video-abuse-object.ts
@@ -0,0 +1,5 @@
1export interface VideoAbuseObject {
2 type: 'Flag',
3 content: string
4 object: string
5}
diff --git a/shared/models/activitypub/objects/video-channel-object.ts b/shared/models/activitypub/objects/video-channel-object.ts
index 72efe42b3..de504d84c 100644
--- a/shared/models/activitypub/objects/video-channel-object.ts
+++ b/shared/models/activitypub/objects/video-channel-object.ts
@@ -1,5 +1,3 @@
1import { ActivityIdentifierObject } from './common-objects'
2
3export interface VideoChannelObject { 1export interface VideoChannelObject {
4 type: 'VideoChannel' 2 type: 'VideoChannel'
5 id: string 3 id: string
diff --git a/shared/models/videos/video-abuse.model.ts b/shared/models/videos/video-abuse.model.ts
index 38041e491..aaedd00d4 100644
--- a/shared/models/videos/video-abuse.model.ts
+++ b/shared/models/videos/video-abuse.model.ts
@@ -1,8 +1,10 @@
1export interface VideoAbuse { 1export interface VideoAbuse {
2 id: number 2 id: number
3 reporterServerHost: string
4 reason: string 3 reason: string
5 reporterUsername: string 4 reporterUsername: string
5 reporterServerHost: string
6 videoId: number 6 videoId: number
7 videoUUID: string
8 videoName: string
7 createdAt: Date 9 createdAt: Date
8} 10}