X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Fmodels%2Fvideo%2Fvideo.ts;h=4516b9c7b88d57b61b74dcd41903cd997c564ca9;hb=9b39106d5757caf221a88e42e05167a6fac479c6;hp=fe81fab1ae4a7e9626527423894734840f4d4fd8;hpb=31d065cc50e17a9abf263ed8c606cb272cd4933d;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/models/video/video.ts b/server/models/video/video.ts index fe81fab1a..4516b9c7b 100644 --- a/server/models/video/video.ts +++ b/server/models/video/video.ts @@ -1313,7 +1313,7 @@ export class VideoModel extends Model { static loadWithFiles (id: number, t?: Sequelize.Transaction, logging?: boolean) { return VideoModel.scope([ ScopeNames.WITH_FILES, ScopeNames.WITH_STREAMING_PLAYLISTS ]) - .findById(id, { transaction: t, logging }) + .findByPk(id, { transaction: t, logging }) } static loadByUUIDWithFile (uuid: string) {