diff options
Diffstat (limited to 'server/types')
-rw-r--r-- | server/types/models/moderation/abuse.ts | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/server/types/models/moderation/abuse.ts b/server/types/models/moderation/abuse.ts index abbc93d6f..8e12be874 100644 --- a/server/types/models/moderation/abuse.ts +++ b/server/types/models/moderation/abuse.ts | |||
@@ -3,7 +3,7 @@ import { VideoCommentAbuseModel } from '@server/models/abuse/video-comment-abuse | |||
3 | import { PickWith } from '@shared/core-utils' | 3 | import { PickWith } from '@shared/core-utils' |
4 | import { AbuseModel } from '../../../models/abuse/abuse' | 4 | import { AbuseModel } from '../../../models/abuse/abuse' |
5 | import { MAccountDefault, MAccountFormattable, MAccountLight, MAccountUrl } from '../account' | 5 | import { MAccountDefault, MAccountFormattable, MAccountLight, MAccountUrl } from '../account' |
6 | import { MCommentOwner, MCommentUrl, MVideoUrl, MCommentOwnerVideo } from '../video' | 6 | import { MCommentOwner, MCommentUrl, MVideoUrl, MCommentOwnerVideo, MComment, MCommentVideo } from '../video' |
7 | import { MVideo, MVideoAccountLightBlacklistAllFiles } from '../video/video' | 7 | import { MVideo, MVideoAccountLightBlacklistAllFiles } from '../video/video' |
8 | 8 | ||
9 | type Use<K extends keyof AbuseModel, M> = PickWith<AbuseModel, K, M> | 9 | type Use<K extends keyof AbuseModel, M> = PickWith<AbuseModel, K, M> |
@@ -51,6 +51,10 @@ export type MCommentAbuseUrl = | |||
51 | MCommentAbuse & | 51 | MCommentAbuse & |
52 | UseCommentAbuse<'VideoComment', MCommentUrl> | 52 | UseCommentAbuse<'VideoComment', MCommentUrl> |
53 | 53 | ||
54 | export type MCommentAbuseFormattable = | ||
55 | MCommentAbuse & | ||
56 | UseCommentAbuse<'VideoComment', MComment & PickWith<MCommentVideo, 'Video', Pick<MVideo, 'id' | 'uuid' | 'name'>>> | ||
57 | |||
54 | // ############################################################################ | 58 | // ############################################################################ |
55 | 59 | ||
56 | export type MAbuseId = Pick<AbuseModel, 'id'> | 60 | export type MAbuseId = Pick<AbuseModel, 'id'> |
@@ -94,4 +98,5 @@ export type MAbuseFull = | |||
94 | export type MAbuseFormattable = | 98 | export type MAbuseFormattable = |
95 | MAbuse & | 99 | MAbuse & |
96 | Use<'ReporterAccount', MAccountFormattable> & | 100 | Use<'ReporterAccount', MAccountFormattable> & |
97 | Use<'VideoAbuse', MVideoAbuseFormattable> | 101 | Use<'VideoAbuse', MVideoAbuseFormattable> & |
102 | Use<'VideoCommentAbuse', MCommentAbuseFormattable> | ||