Remove uneccessary details to link titles
[oweals/peertube.git] / server / typings / models / video / video-abuse.ts
index e38c3f58600585e7af33d7a363d42101e313e6e4..d60f05e4cd21413b1e1e06749d0856f2147a2afd 100644 (file)
@@ -1,6 +1,6 @@
 import { VideoAbuseModel } from '../../../models/video/video-abuse'
 import { PickWith } from '../../utils'
-import { MVideo } from './video'
+import { MVideoAccountLightBlacklistAllFiles, MVideo } from './video'
 import { MAccountDefault, MAccountFormattable } from '../account'
 
 type Use<K extends keyof VideoAbuseModel, M> = PickWith<VideoAbuseModel, K, M>
@@ -13,19 +13,23 @@ export type MVideoAbuse = Omit<VideoAbuseModel, 'Account' | 'Video' | 'toActivit
 
 export type MVideoAbuseId = Pick<VideoAbuseModel, 'id'>
 
-export type MVideoAbuseVideo = MVideoAbuse &
+export type MVideoAbuseVideo =
+  MVideoAbuse &
   Pick<VideoAbuseModel, 'toActivityPubObject'> &
   Use<'Video', MVideo>
 
-export type MVideoAbuseAccountVideo = MVideoAbuse &
+export type MVideoAbuseAccountVideo =
+  MVideoAbuse &
   Pick<VideoAbuseModel, 'toActivityPubObject'> &
-  Use<'Video', MVideo> &
+  Use<'Video', MVideoAccountLightBlacklistAllFiles> &
   Use<'Account', MAccountDefault>
 
 // ############################################################################
 
 // Format for API or AP object
 
-export type MVideoAbuseFormattable = MVideoAbuse &
+export type MVideoAbuseFormattable =
+  MVideoAbuse &
   Use<'Account', MAccountFormattable> &
-  Use<'Video', Pick<MVideo, 'id' | 'uuid' | 'name'>>
+  Use<'Video', Pick<MVideoAccountLightBlacklistAllFiles,
+  'id' | 'uuid' | 'name' | 'nsfw' | 'getMiniatureStaticPath' | 'isBlacklisted' | 'VideoChannel'>>