From 037e14d4adaabee37c6c31e89e7477857626fbcd Mon Sep 17 00:00:00 2001 From: will Date: Thu, 15 Dec 2022 15:45:09 +0800 Subject: [PATCH] Fixed the problem that comment reply cannot be displayed in the front end (#2954) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #### What type of PR is this? /kind bug #### What this PR does / why we need it: /kind api-change #### Which issue(s) this PR fixes: Fixes #2951 #### Special notes for your reviewer: #### Does this PR introduce a user-facing change? ```release-note 修复开启评论审核的情况下无法显示评论回复的问题 ``` --- .../java/run/halo/app/content/comment/ReplyServiceImpl.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/run/halo/app/content/comment/ReplyServiceImpl.java b/src/main/java/run/halo/app/content/comment/ReplyServiceImpl.java index f85f0c4d8..59aff87e9 100644 --- a/src/main/java/run/halo/app/content/comment/ReplyServiceImpl.java +++ b/src/main/java/run/halo/app/content/comment/ReplyServiceImpl.java @@ -62,7 +62,8 @@ public class ReplyServiceImpl implements ReplyService { } reply.getSpec().setApproved( Boolean.FALSE.equals(commentSetting.getRequireReviewForNew())); - reply.getSpec().setHidden(!reply.getSpec().getApproved()); + // fix https://github.com/halo-dev/halo/issues/2951 + reply.getSpec().setHidden(false); if (BooleanUtils.isTrue(reply.getSpec().getApproved()) && reply.getSpec().getApprovedTime() == null) {