diff --git a/lazy_github/ui/widgets/conversations.py b/lazy_github/ui/widgets/conversations.py index cbdac4d..8aed339 100644 --- a/lazy_github/ui/widgets/conversations.py +++ b/lazy_github/ui/widgets/conversations.py @@ -111,10 +111,11 @@ def compose(self) -> ComposeResult: else: review_state_text = self.review.state.title() yield Label(f"Review from {self.review.user.login} ({review_state_text})") - yield Markdown(self.review.body) - for comment in self.review.comments: - if comment_node := self.hierarchy[comment.id]: - yield ReviewConversation(self.pr, comment_node) + if self.review.body: + yield Markdown(self.review.body) + for comment in self.review.comments: + if comment_node := self.hierarchy[comment.id]: + yield ReviewConversation(self.pr, comment_node) def action_reply_to_review(self) -> None: self.app.push_screen(NewCommentModal(self.pr.repo, self.pr, self.review)) diff --git a/lazy_github/ui/widgets/pull_requests.py b/lazy_github/ui/widgets/pull_requests.py index a375053..6a9931d 100644 --- a/lazy_github/ui/widgets/pull_requests.py +++ b/lazy_github/ui/widgets/pull_requests.py @@ -315,8 +315,8 @@ async def fetch_conversation(self) -> None: for review in reviews: if review.body: handled_comment_node_ids.extend([c.id for c in review.comments]) - review_container = ReviewContainer(self.pr, review, review_hierarchy) - self.comments_and_reviews.mount(review_container) + review_container = ReviewContainer(self.pr, review, review_hierarchy) + self.comments_and_reviews.mount(review_container) for comment in comments: if comment.body and comment.id not in handled_comment_node_ids: