1
0
Fork 0
peertube/server/typings/models/oauth/oauth-token.ts
Chocobozzz d7a25329f9
Add ability to disable webtorrent
In favour of HLS
2019-11-25 10:59:43 +01:00

13 lines
505 B
TypeScript

import { OAuthTokenModel } from '@server/models/oauth/oauth-token'
import { PickWith } from '@server/typings/utils'
import { MUserAccountUrl } from '../user/user'
type Use<K extends keyof OAuthTokenModel, M> = PickWith<OAuthTokenModel, K, M>
// ############################################################################
export type MOAuthToken = Omit<OAuthTokenModel, 'User' | 'OAuthClients'>
export type MOAuthTokenUser = MOAuthToken &
Use<'User', MUserAccountUrl> &
{ user?: MUserAccountUrl }