1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-03 09:49:20 +02:00

Fix ownership changes count

This commit is contained in:
Chocobozzz 2025-05-26 10:00:30 +02:00
parent ca2c6139ef
commit 056a94a44d
No known key found for this signature in database
GPG key ID: 583A612D890159BE

View file

@ -113,7 +113,7 @@ export class VideoChangeOwnershipModel extends SequelizeModel<VideoChangeOwnersh
}
return Promise.all([
VideoChangeOwnershipModel.scope(ScopeNames.WITH_ACCOUNTS).count(query),
VideoChangeOwnershipModel.count(query),
VideoChangeOwnershipModel.scope([ ScopeNames.WITH_ACCOUNTS, ScopeNames.WITH_VIDEO ]).findAll<MVideoChangeOwnershipFull>(query)
]).then(([ count, rows ]) => ({ total: count, data: rows }))
}