From 1a230c85b549cf31e6584c99af05e271dfe049a1 Mon Sep 17 00:00:00 2001 From: Snowykami Date: Fri, 12 Sep 2025 13:12:09 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20Closes=20#4=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E8=AF=84=E8=AE=BA=E5=8F=91=E5=B8=83=E6=97=B6=E4=B9=8B=E5=89=8D?= =?UTF-8?q?=E7=9A=84=E8=AF=84=E8=AE=BA=E8=A2=AB=E7=A7=BB=E5=87=BA=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/src/components/comment/index.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/web/src/components/comment/index.tsx b/web/src/components/comment/index.tsx index 6f5d1f3..ee0b7ea 100644 --- a/web/src/components/comment/index.tsx +++ b/web/src/components/comment/index.tsx @@ -71,7 +71,6 @@ export function CommentSection( }).then(res => { toast.success(t("comment_success")); setTotalCommentCount(c => c + 1); - setComments(prevComments => prevComments.slice(0, -1)); getComment({ id: res.data.id }).then(response => { console.log("New comment fetched:", response.data); setComments(prevComments => [response.data, ...prevComments]);