X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Flib%2Fvideo-comment.ts;h=59bce7520af4c1732988d49b81f6f0347123413d;hb=9644c2a88eb227e7441b0f0a75abb75b41cc60ca;hp=70ba7c3039cd947c3636d65d64418e80f810d111;hpb=c1e791bad0b079af67398f6407221e6dcbb573dd;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/lib/video-comment.ts b/server/lib/video-comment.ts index 70ba7c303..59bce7520 100644 --- a/server/lib/video-comment.ts +++ b/server/lib/video-comment.ts @@ -64,10 +64,8 @@ function buildFormattedCommentTree (resultList: ResultList): } const parentCommentThread = idx[childComment.inReplyToCommentId] - if (!parentCommentThread) { - const msg = `Cannot format video thread tree, parent ${childComment.inReplyToCommentId} not found for child ${childComment.id}` - throw new Error(msg) - } + // Maybe the parent comment was blocked by the admin/user + if (!parentCommentThread) continue parentCommentThread.children.push(childCommentThread) idx[childComment.id] = childCommentThread