+ logger.info('Remote video channel %s removed.', videoChannelToRemove.Actor.url)
+}
+
+function processDeleteVideoComment (byActor: ActorModel, videoComment: VideoCommentModel, activity: ActivityDelete) {
+ logger.debug('Removing remote video comment "%s".', videoComment.url)
+
+ return sequelizeTypescript.transaction(async t => {
+ if (videoComment.Account.id !== byActor.Account.id) {
+ throw new Error('Account ' + byActor.url + ' does not own video comment ' + videoComment.url)
+ }
+
+ await videoComment.destroy({ transaction: t })
+
+ if (videoComment.Video.isOwned()) {
+ // Don't resend the activity to the sender
+ const exceptions = [ byActor ]
+ await forwardVideoRelatedActivity(activity, t, exceptions, videoComment.Video)
+ }
+
+ logger.info('Remote video comment %s removed.', videoComment.url)
+ })