aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/typings/models/video/video-rate.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-08-20 19:05:31 +0200
committerChocobozzz <me@florianbigard.com>2019-08-20 19:23:10 +0200
commit1ca9f7c3f7afac2af4c4c25b98426731f7e789c6 (patch)
tree27fe65c4ea5e9250d2523033d5c65b315bfca23d /server/typings/models/video/video-rate.ts
parent0283eaac2a8e73006c66df3cf5bb9012e37450e5 (diff)
downloadPeerTube-1ca9f7c3f7afac2af4c4c25b98426731f7e789c6.tar.gz
PeerTube-1ca9f7c3f7afac2af4c4c25b98426731f7e789c6.tar.zst
PeerTube-1ca9f7c3f7afac2af4c4c25b98426731f7e789c6.zip
Type toFormattedJSON
Diffstat (limited to 'server/typings/models/video/video-rate.ts')
-rw-r--r--server/typings/models/video/video-rate.ts9
1 files changed, 8 insertions, 1 deletions
diff --git a/server/typings/models/video/video-rate.ts b/server/typings/models/video/video-rate.ts
index fc9329993..2ff8a625b 100644
--- a/server/typings/models/video/video-rate.ts
+++ b/server/typings/models/video/video-rate.ts
@@ -1,6 +1,6 @@
1import { AccountVideoRateModel } from '@server/models/account/account-video-rate' 1import { AccountVideoRateModel } from '@server/models/account/account-video-rate'
2import { PickWith } from '@server/typings/utils' 2import { PickWith } from '@server/typings/utils'
3import { MAccountAudience, MAccountUrl, MVideo } from '..' 3import { MAccountAudience, MAccountUrl, MVideo, MVideoFormattable } from '..'
4 4
5type Use<K extends keyof AccountVideoRateModel, M> = PickWith<AccountVideoRateModel, K, M> 5type Use<K extends keyof AccountVideoRateModel, M> = PickWith<AccountVideoRateModel, K, M>
6 6
@@ -14,3 +14,10 @@ export type MAccountVideoRateAccountUrl = MAccountVideoRate &
14export type MAccountVideoRateAccountVideo = MAccountVideoRate & 14export type MAccountVideoRateAccountVideo = MAccountVideoRate &
15 Use<'Account', MAccountAudience> & 15 Use<'Account', MAccountAudience> &
16 Use<'Video', MVideo> 16 Use<'Video', MVideo>
17
18// ############################################################################
19
20// Format for API or AP object
21
22export type MAccountVideoRateFormattable = Pick<MAccountVideoRate, 'type'> &
23 Use<'Video', MVideoFormattable>