From 94a5ff8a4a75d75bb9df542a39ce8769e7a7e6a4 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 25 Jan 2018 15:05:18 +0100 Subject: Move job queue to redis We'll use it as cache in the future. /!\ You'll loose your old jobs (pending jobs too) so upgrade only when you don't have pending job anymore. --- server/lib/activitypub/send/send-undo.ts | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'server/lib/activitypub/send/send-undo.ts') diff --git a/server/lib/activitypub/send/send-undo.ts b/server/lib/activitypub/send/send-undo.ts index 3a0597fba..4a08b5ca1 100644 --- a/server/lib/activitypub/send/send-undo.ts +++ b/server/lib/activitypub/send/send-undo.ts @@ -1,11 +1,5 @@ import { Transaction } from 'sequelize' -import { - ActivityAudience, - ActivityCreate, - ActivityFollow, - ActivityLike, - ActivityUndo -} from '../../../../shared/models/activitypub' +import { ActivityAudience, ActivityCreate, ActivityFollow, ActivityLike, ActivityUndo } from '../../../../shared/models/activitypub' import { ActorModel } from '../../../models/activitypub/actor' import { ActorFollowModel } from '../../../models/activitypub/actor-follow' import { VideoModel } from '../../../models/video/video' @@ -33,7 +27,7 @@ async function sendUndoFollow (actorFollow: ActorFollowModel, t: Transaction) { const object = followActivityData(followUrl, me, following) const data = await undoActivityData(undoUrl, me, object, t) - return unicastTo(data, me, following.inboxUrl, t) + return unicastTo(data, me, following.inboxUrl) } async function sendUndoLikeToOrigin (byActor: ActorModel, video: VideoModel, t: Transaction) { @@ -45,7 +39,7 @@ async function sendUndoLikeToOrigin (byActor: ActorModel, video: VideoModel, t: const object = await likeActivityData(likeUrl, byActor, video, t) const data = await undoActivityData(undoUrl, byActor, object, t, audience) - return unicastTo(data, byActor, video.VideoChannel.Account.Actor.sharedInboxUrl, t) + return unicastTo(data, byActor, video.VideoChannel.Account.Actor.sharedInboxUrl) } async function sendUndoLikeToVideoFollowers (byActor: ActorModel, video: VideoModel, t: Transaction) { @@ -72,7 +66,7 @@ async function sendUndoDislikeToOrigin (byActor: ActorModel, video: VideoModel, const data = await undoActivityData(undoUrl, byActor, object, t, audience) - return unicastTo(data, byActor, video.VideoChannel.Account.Actor.sharedInboxUrl, t) + return unicastTo(data, byActor, video.VideoChannel.Account.Actor.sharedInboxUrl) } async function sendUndoDislikeToVideoFollowers (byActor: ActorModel, video: VideoModel, t: Transaction) { -- cgit v1.2.3