ActivityPub-federated video streaming platform using P2P directly in your web browser
Check the comment is defined when validating body
Chocobozzzc049d791f92c
diff --git a/server/helpers/custom-validators/activitypub/video-comments.ts b/server/helpers/custom-validators/activitypub/video-comments.tsindex 7a9f7326d1..051c4565ab 100644--- a/server/helpers/custom-validators/activitypub/video-comments.ts+++ b/server/helpers/custom-validators/activitypub/video-comments.ts@@ -9,7 +9,7 @@ function isVideoCommentCreateActivityValid (activity: any) {}function sanitizeAndCheckVideoCommentObject (comment: any) {- if (comment.type !== 'Note') return false+ if (!comment || comment.type !== 'Note') return falsenormalizeComment(comment)