diff options
author | Chocobozzz <me@florianbigard.com> | 2018-08-22 16:15:35 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-08-27 09:41:54 +0200 |
commit | 1297eb5db651a230474670c5da1517862fb9cc3e (patch) | |
tree | ecad4a0ceb0bb09e3c775262691ac68e9e0aca0c /server/lib/activitypub/process/process-undo.ts | |
parent | f6eebcb336c067e160a62020a5140d8d992ba384 (diff) | |
download | PeerTube-1297eb5db651a230474670c5da1517862fb9cc3e.tar.gz PeerTube-1297eb5db651a230474670c5da1517862fb9cc3e.tar.zst PeerTube-1297eb5db651a230474670c5da1517862fb9cc3e.zip |
Add refresh video on search
Diffstat (limited to 'server/lib/activitypub/process/process-undo.ts')
-rw-r--r-- | server/lib/activitypub/process/process-undo.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/server/lib/activitypub/process/process-undo.ts b/server/lib/activitypub/process/process-undo.ts index b6de107ad..eab9e3d61 100644 --- a/server/lib/activitypub/process/process-undo.ts +++ b/server/lib/activitypub/process/process-undo.ts | |||
@@ -9,7 +9,7 @@ import { AccountVideoRateModel } from '../../../models/account/account-video-rat | |||
9 | import { ActorModel } from '../../../models/activitypub/actor' | 9 | import { ActorModel } from '../../../models/activitypub/actor' |
10 | import { ActorFollowModel } from '../../../models/activitypub/actor-follow' | 10 | import { ActorFollowModel } from '../../../models/activitypub/actor-follow' |
11 | import { forwardVideoRelatedActivity } from '../send/utils' | 11 | import { forwardVideoRelatedActivity } from '../send/utils' |
12 | import { getOrCreateAccountAndVideoAndChannel } from '../videos' | 12 | import { getOrCreateVideoAndAccountAndChannel } from '../videos' |
13 | import { VideoShareModel } from '../../../models/video/video-share' | 13 | import { VideoShareModel } from '../../../models/video/video-share' |
14 | 14 | ||
15 | async function processUndoActivity (activity: ActivityUndo) { | 15 | async function processUndoActivity (activity: ActivityUndo) { |
@@ -43,7 +43,7 @@ export { | |||
43 | async function processUndoLike (actorUrl: string, activity: ActivityUndo) { | 43 | async function processUndoLike (actorUrl: string, activity: ActivityUndo) { |
44 | const likeActivity = activity.object as ActivityLike | 44 | const likeActivity = activity.object as ActivityLike |
45 | 45 | ||
46 | const { video } = await getOrCreateAccountAndVideoAndChannel(likeActivity.object) | 46 | const { video } = await getOrCreateVideoAndAccountAndChannel(likeActivity.object) |
47 | 47 | ||
48 | return sequelizeTypescript.transaction(async t => { | 48 | return sequelizeTypescript.transaction(async t => { |
49 | const byAccount = await AccountModel.loadByUrl(actorUrl, t) | 49 | const byAccount = await AccountModel.loadByUrl(actorUrl, t) |
@@ -67,7 +67,7 @@ async function processUndoLike (actorUrl: string, activity: ActivityUndo) { | |||
67 | async function processUndoDislike (actorUrl: string, activity: ActivityUndo) { | 67 | async function processUndoDislike (actorUrl: string, activity: ActivityUndo) { |
68 | const dislike = activity.object.object as DislikeObject | 68 | const dislike = activity.object.object as DislikeObject |
69 | 69 | ||
70 | const { video } = await getOrCreateAccountAndVideoAndChannel(dislike.object) | 70 | const { video } = await getOrCreateVideoAndAccountAndChannel(dislike.object) |
71 | 71 | ||
72 | return sequelizeTypescript.transaction(async t => { | 72 | return sequelizeTypescript.transaction(async t => { |
73 | const byAccount = await AccountModel.loadByUrl(actorUrl, t) | 73 | const byAccount = await AccountModel.loadByUrl(actorUrl, t) |