From 491d5156531cf11152bbdf3314a8b08c074faaad Mon Sep 17 00:00:00 2001 From: Krzysztof Kocot Date: Tue, 16 Dec 2025 14:13:40 +0100 Subject: [PATCH] Fix nested comments not displaying on comment view page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When opening a comment directly via URL, nested replies were not shown. The pagination logic hardcoded depth === 1, assuming we're always viewing the main post. Changed to use postData.depth + 1 to correctly find direct replies regardless of the current post/comment depth. Fixes #769 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- apps/blog/app/[param]/[p2]/[permlink]/content.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/blog/app/[param]/[p2]/[permlink]/content.tsx b/apps/blog/app/[param]/[p2]/[permlink]/content.tsx index 171b2f707..6a2cdebfa 100644 --- a/apps/blog/app/[param]/[p2]/[permlink]/content.tsx +++ b/apps/blog/app/[param]/[p2]/[permlink]/content.tsx @@ -172,10 +172,10 @@ const PostContent = () => { commentsByParent.get(parentKey)!.push(comment); }); - // Find all main comments (depth === 1, which are direct replies to the post) + // Find all main comments (direct replies to the current post/comment) const mainComments = discussionState.filter( (comment) => - comment.depth === 1 && + comment.depth === postData.depth + 1 && comment.parent_author === postData.author && comment.parent_permlink === postData.permlink ); -- GitLab