aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-10-02 11:33:18 +0200
committerChocobozzz <me@florianbigard.com>2018-10-02 11:33:18 +0200
commit659edaa62c9728d794ca779ac9a62a092f1c84b5 (patch)
tree9fb8cecea285ff17b604fa96a51ca9fefab69cab
parent53877968a6bff713be6f0e15042e13a5da5e5e1a (diff)
downloadPeerTube-659edaa62c9728d794ca779ac9a62a092f1c84b5.tar.gz
PeerTube-659edaa62c9728d794ca779ac9a62a092f1c84b5.tar.zst
PeerTube-659edaa62c9728d794ca779ac9a62a092f1c84b5.zip
Correctly forward comment deletion
-rw-r--r--server/lib/activitypub/process/process-delete.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/activitypub/process/process-delete.ts b/server/lib/activitypub/process/process-delete.ts
index 038d8c4d3..155d2ffcc 100644
--- a/server/lib/activitypub/process/process-delete.ts
+++ b/server/lib/activitypub/process/process-delete.ts
@@ -7,7 +7,7 @@ import { ActorModel } from '../../../models/activitypub/actor'
7import { VideoModel } from '../../../models/video/video' 7import { VideoModel } from '../../../models/video/video'
8import { VideoChannelModel } from '../../../models/video/video-channel' 8import { VideoChannelModel } from '../../../models/video/video-channel'
9import { VideoCommentModel } from '../../../models/video/video-comment' 9import { VideoCommentModel } from '../../../models/video/video-comment'
10import { forwardActivity } from '../send/utils' 10import { forwardVideoRelatedActivity } from '../send/utils'
11 11
12async function processDeleteActivity (activity: ActivityDelete, byActor: ActorModel) { 12async function processDeleteActivity (activity: ActivityDelete, byActor: ActorModel) {
13 const objectUrl = typeof activity.object === 'string' ? activity.object : activity.object.id 13 const objectUrl = typeof activity.object === 'string' ? activity.object : activity.object.id
@@ -103,7 +103,7 @@ function processDeleteVideoComment (byActor: ActorModel, videoComment: VideoComm
103 if (videoComment.Video.isOwned()) { 103 if (videoComment.Video.isOwned()) {
104 // Don't resend the activity to the sender 104 // Don't resend the activity to the sender
105 const exceptions = [ byActor ] 105 const exceptions = [ byActor ]
106 await forwardActivity(activity, t, exceptions) 106 await forwardVideoRelatedActivity(activity, t, exceptions, videoComment.Video)
107 } 107 }
108 108
109 logger.info('Remote video comment %s removed.', videoComment.url) 109 logger.info('Remote video comment %s removed.', videoComment.url)