From: Chocobozzz Date: Wed, 29 Jan 2020 13:56:07 +0000 (+0100) Subject: Comments enabled attrivute is optional in AP X-Git-Tag: v2.2.0-rc.1~572 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=0bc1b31d60ed0edf3999f51743b653068ef1816e;p=oweals%2Fpeertube.git Comments enabled attrivute is optional in AP --- diff --git a/server/helpers/custom-validators/activitypub/videos.ts b/server/helpers/custom-validators/activitypub/videos.ts index fe94bd58a..224f03f4e 100644 --- a/server/helpers/custom-validators/activitypub/videos.ts +++ b/server/helpers/custom-validators/activitypub/videos.ts @@ -56,6 +56,7 @@ function sanitizeAndCheckVideoTorrentObject (video: any) { if (!isVideoStateValid(video.state)) video.state = VideoState.PUBLISHED if (!isBooleanValid(video.waitTranscoding)) video.waitTranscoding = false if (!isBooleanValid(video.downloadEnabled)) video.downloadEnabled = true + if (!isBooleanValid(video.commentsEnabled)) video.commentsEnabled = false return isActivityPubUrlValid(video.id) && isVideoNameValid(video.name) &&