]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/models/oauth/oauth-token.ts
add title attribute for exact view counters (#3365)
[github/Chocobozzz/PeerTube.git] / server / models / oauth / oauth-token.ts
index 3541b6103811f6a3d6d5a9443a7f84c26e8b8ad4..7f2313dad169588ca1f8a875acf438e7c3f729b9 100644 (file)
@@ -19,7 +19,7 @@ import { AccountModel } from '../account/account'
 import { ActorModel } from '../activitypub/actor'
 import { clearCacheByToken } from '../../lib/oauth-model'
 import * as Bluebird from 'bluebird'
-import { MOAuthTokenUser } from '@server/typings/models/oauth/oauth-token'
+import { MOAuthTokenUser } from '@server/types/models/oauth/oauth-token'
 
 export type OAuthTokenInfo = {
   refreshToken: string
@@ -164,9 +164,7 @@ export class OAuthTokenModel extends Model<OAuthTokenModel> {
                               client: {
                                 id: token.oAuthClientId
                               },
-                              user: {
-                                id: token.userId
-                              },
+                              user: token.User,
                               token
                             } as OAuthTokenInfo
                           })