diff options
author | Chocobozzz <me@florianbigard.com> | 2018-10-02 11:33:18 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-10-02 11:33:18 +0200 |
commit | 659edaa62c9728d794ca779ac9a62a092f1c84b5 (patch) | |
tree | 9fb8cecea285ff17b604fa96a51ca9fefab69cab /server/lib | |
parent | 53877968a6bff713be6f0e15042e13a5da5e5e1a (diff) | |
download | PeerTube-659edaa62c9728d794ca779ac9a62a092f1c84b5.tar.gz PeerTube-659edaa62c9728d794ca779ac9a62a092f1c84b5.tar.zst PeerTube-659edaa62c9728d794ca779ac9a62a092f1c84b5.zip |
Correctly forward comment deletion
Diffstat (limited to 'server/lib')
-rw-r--r-- | server/lib/activitypub/process/process-delete.ts | 4 |
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' | |||
7 | import { VideoModel } from '../../../models/video/video' | 7 | import { VideoModel } from '../../../models/video/video' |
8 | import { VideoChannelModel } from '../../../models/video/video-channel' | 8 | import { VideoChannelModel } from '../../../models/video/video-channel' |
9 | import { VideoCommentModel } from '../../../models/video/video-comment' | 9 | import { VideoCommentModel } from '../../../models/video/video-comment' |
10 | import { forwardActivity } from '../send/utils' | 10 | import { forwardVideoRelatedActivity } from '../send/utils' |
11 | 11 | ||
12 | async function processDeleteActivity (activity: ActivityDelete, byActor: ActorModel) { | 12 | async 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) |