aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib/activitypub/process/process-like.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-08-22 16:15:35 +0200
committerChocobozzz <me@florianbigard.com>2018-08-27 09:41:54 +0200
commit1297eb5db651a230474670c5da1517862fb9cc3e (patch)
treeecad4a0ceb0bb09e3c775262691ac68e9e0aca0c /server/lib/activitypub/process/process-like.ts
parentf6eebcb336c067e160a62020a5140d8d992ba384 (diff)
downloadPeerTube-1297eb5db651a230474670c5da1517862fb9cc3e.tar.gz
PeerTube-1297eb5db651a230474670c5da1517862fb9cc3e.tar.zst
PeerTube-1297eb5db651a230474670c5da1517862fb9cc3e.zip
Add refresh video on search
Diffstat (limited to 'server/lib/activitypub/process/process-like.ts')
-rw-r--r--server/lib/activitypub/process/process-like.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/activitypub/process/process-like.ts b/server/lib/activitypub/process/process-like.ts
index d0865b78c..9e1664fd8 100644
--- a/server/lib/activitypub/process/process-like.ts
+++ b/server/lib/activitypub/process/process-like.ts
@@ -5,7 +5,7 @@ import { AccountVideoRateModel } from '../../../models/account/account-video-rat
5import { ActorModel } from '../../../models/activitypub/actor' 5import { ActorModel } from '../../../models/activitypub/actor'
6import { getOrCreateActorAndServerAndModel } from '../actor' 6import { getOrCreateActorAndServerAndModel } from '../actor'
7import { forwardVideoRelatedActivity } from '../send/utils' 7import { forwardVideoRelatedActivity } from '../send/utils'
8import { getOrCreateAccountAndVideoAndChannel } from '../videos' 8import { getOrCreateVideoAndAccountAndChannel } from '../videos'
9 9
10async function processLikeActivity (activity: ActivityLike) { 10async function processLikeActivity (activity: ActivityLike) {
11 const actor = await getOrCreateActorAndServerAndModel(activity.actor) 11 const actor = await getOrCreateActorAndServerAndModel(activity.actor)
@@ -27,7 +27,7 @@ async function processLikeVideo (byActor: ActorModel, activity: ActivityLike) {
27 const byAccount = byActor.Account 27 const byAccount = byActor.Account
28 if (!byAccount) throw new Error('Cannot create like with the non account actor ' + byActor.url) 28 if (!byAccount) throw new Error('Cannot create like with the non account actor ' + byActor.url)
29 29
30 const { video } = await getOrCreateAccountAndVideoAndChannel(videoUrl) 30 const { video } = await getOrCreateVideoAndAccountAndChannel(videoUrl)
31 31
32 return sequelizeTypescript.transaction(async t => { 32 return sequelizeTypescript.transaction(async t => {
33 const rate = { 33 const rate = {