From 1297eb5db651a230474670c5da1517862fb9cc3e Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 22 Aug 2018 16:15:35 +0200 Subject: Add refresh video on search --- server/lib/activitypub/process/process-like.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'server/lib/activitypub/process/process-like.ts') 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 import { ActorModel } from '../../../models/activitypub/actor' import { getOrCreateActorAndServerAndModel } from '../actor' import { forwardVideoRelatedActivity } from '../send/utils' -import { getOrCreateAccountAndVideoAndChannel } from '../videos' +import { getOrCreateVideoAndAccountAndChannel } from '../videos' async function processLikeActivity (activity: ActivityLike) { const actor = await getOrCreateActorAndServerAndModel(activity.actor) @@ -27,7 +27,7 @@ async function processLikeVideo (byActor: ActorModel, activity: ActivityLike) { const byAccount = byActor.Account if (!byAccount) throw new Error('Cannot create like with the non account actor ' + byActor.url) - const { video } = await getOrCreateAccountAndVideoAndChannel(videoUrl) + const { video } = await getOrCreateVideoAndAccountAndChannel(videoUrl) return sequelizeTypescript.transaction(async t => { const rate = { -- cgit v1.2.3