diff options
Diffstat (limited to 'server/lib/activitypub')
-rw-r--r-- | server/lib/activitypub/process/process-undo.ts | 8 | ||||
-rw-r--r-- | server/lib/activitypub/send/send-undo.ts | 9 |
2 files changed, 8 insertions, 9 deletions
diff --git a/server/lib/activitypub/process/process-undo.ts b/server/lib/activitypub/process/process-undo.ts index caa835714..9fe066c01 100644 --- a/server/lib/activitypub/process/process-undo.ts +++ b/server/lib/activitypub/process/process-undo.ts | |||
@@ -1,10 +1,10 @@ | |||
1 | import { ActivityCreate, ActivityFollow, ActivityLike, ActivityUndo } from '../../../../shared/models/activitypub/activity' | 1 | import { ActivityFollow, ActivityLike, ActivityUndo } from '../../../../shared/models/activitypub/activity' |
2 | import { DislikeObject } from '../../../../shared/models/activitypub/objects/dislike-object' | ||
3 | import { retryTransactionWrapper } from '../../../helpers/database-utils' | ||
2 | import { logger } from '../../../helpers/logger' | 4 | import { logger } from '../../../helpers/logger' |
3 | import { database as db } from '../../../initializers' | 5 | import { database as db } from '../../../initializers' |
4 | import { retryTransactionWrapper } from '../../../helpers/database-utils' | ||
5 | import { DislikeObject } from '../../../../shared/models/activitypub/objects/dislike-object' | ||
6 | import { sendUndoLikeToVideoFollowers } from '../send/send-undo' | ||
7 | import { sendUndoDislikeToVideoFollowers } from '../index' | 6 | import { sendUndoDislikeToVideoFollowers } from '../index' |
7 | import { sendUndoLikeToVideoFollowers } from '../send/send-undo' | ||
8 | 8 | ||
9 | async function processUndoActivity (activity: ActivityUndo) { | 9 | async function processUndoActivity (activity: ActivityUndo) { |
10 | const activityToUndo = activity.object | 10 | const activityToUndo = activity.object |
diff --git a/server/lib/activitypub/send/send-undo.ts b/server/lib/activitypub/send/send-undo.ts index 53fddd0cb..8f46a051e 100644 --- a/server/lib/activitypub/send/send-undo.ts +++ b/server/lib/activitypub/send/send-undo.ts | |||
@@ -1,14 +1,14 @@ | |||
1 | import { Transaction } from 'sequelize' | 1 | import { Transaction } from 'sequelize' |
2 | import { ActivityCreate, ActivityFollow, ActivityLike, ActivityUndo } from '../../../../shared/models/activitypub/activity' | 2 | import { ActivityCreate, ActivityFollow, ActivityLike, ActivityUndo } from '../../../../shared/models/activitypub/activity' |
3 | import { getServerAccount } from '../../../helpers/utils' | ||
3 | import { AccountInstance } from '../../../models' | 4 | import { AccountInstance } from '../../../models' |
4 | import { AccountFollowInstance } from '../../../models/account/account-follow-interface' | 5 | import { AccountFollowInstance } from '../../../models/account/account-follow-interface' |
6 | import { VideoInstance } from '../../../models/video/video-interface' | ||
7 | import { getAccountFollowActivityPubUrl, getUndoActivityPubUrl, getVideoDislikeActivityPubUrl, getVideoLikeActivityPubUrl } from '../url' | ||
5 | import { broadcastToFollowers, getAccountsToForwardVideoAction, unicastTo } from './misc' | 8 | import { broadcastToFollowers, getAccountsToForwardVideoAction, unicastTo } from './misc' |
9 | import { createActivityData, createDislikeActivityData } from './send-create' | ||
6 | import { followActivityData } from './send-follow' | 10 | import { followActivityData } from './send-follow' |
7 | import { getAccountFollowActivityPubUrl, getUndoActivityPubUrl, getVideoDislikeActivityPubUrl, getVideoLikeActivityPubUrl } from '../url' | ||
8 | import { VideoInstance } from '../../../models/video/video-interface' | ||
9 | import { likeActivityData } from './send-like' | 11 | import { likeActivityData } from './send-like' |
10 | import { createActivityData, createDislikeActivityData } from './send-create' | ||
11 | import { getServerAccount } from '../../../helpers/utils' | ||
12 | 12 | ||
13 | async function sendUndoFollow (accountFollow: AccountFollowInstance, t: Transaction) { | 13 | async function sendUndoFollow (accountFollow: AccountFollowInstance, t: Transaction) { |
14 | const me = accountFollow.AccountFollower | 14 | const me = accountFollow.AccountFollower |
@@ -75,7 +75,6 @@ async function sendUndoDislikeToVideoFollowers (byAccount: AccountInstance, vide | |||
75 | return broadcastToFollowers(data, serverAccount, accountsToForwardView, t, followersException) | 75 | return broadcastToFollowers(data, serverAccount, accountsToForwardView, t, followersException) |
76 | } | 76 | } |
77 | 77 | ||
78 | |||
79 | // --------------------------------------------------------------------------- | 78 | // --------------------------------------------------------------------------- |
80 | 79 | ||
81 | export { | 80 | export { |