mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-06 03:50:26 +02:00
Upgrade sequelize to v6
This commit is contained in:
parent
6c8c15f914
commit
b49f22d8f9
75 changed files with 436 additions and 498 deletions
|
@ -33,7 +33,7 @@ async function processDislike (activity: ActivityCreate | ActivityDislike, byAct
|
|||
const { video } = await getOrCreateVideoAndAccountAndChannel({ videoObject: dislikeObject })
|
||||
|
||||
return sequelizeTypescript.transaction(async t => {
|
||||
const existingRate = await AccountVideoRateModel.loadByAccountAndVideoOrUrl(byAccount.id, video.id, activity.id)
|
||||
const existingRate = await AccountVideoRateModel.loadByAccountAndVideoOrUrl(byAccount.id, video.id, activity.id, t)
|
||||
if (existingRate && existingRate.type === 'dislike') return
|
||||
|
||||
await video.increment('dislikes', { transaction: t })
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue