1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-04 10:19:35 +02:00

Stricter models typing

This commit is contained in:
Chocobozzz 2021-05-12 14:09:04 +02:00
parent 9a320a06b6
commit 16c016e8b1
No known key found for this signature in database
GPG key ID: 583A612D890159BE
54 changed files with 148 additions and 95 deletions

View file

@ -15,6 +15,7 @@ import {
import { TokensCache } from '@server/lib/auth/tokens-cache'
import { MUserAccountId } from '@server/types/models'
import { MOAuthTokenUser } from '@server/types/models/oauth/oauth-token'
import { AttributesOnly } from '@shared/core-utils'
import { logger } from '../../helpers/logger'
import { AccountModel } from '../account/account'
import { ActorModel } from '../actor/actor'
@ -78,7 +79,7 @@ enum ScopeNames {
}
]
})
export class OAuthTokenModel extends Model {
export class OAuthTokenModel extends Model<Partial<AttributesOnly<OAuthTokenModel>>> {
@AllowNull(false)
@Column