From 09b5f151440da4687b540d6f4b57adfef20b09d0 Mon Sep 17 00:00:00 2001 From: zer0silver Date: Tue, 10 Sep 2024 14:01:49 +0900 Subject: [PATCH] =?UTF-8?q?refactor:=20Boolean=20=EA=B0=9D=EC=B2=B4=20?= =?UTF-8?q?=EC=82=AC=EC=9A=A9=20&=20nullable=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../capple/domain/boardComment/entity/BoardComment.java | 5 ++--- .../domain/boardComment/mapper/BoardCommentMapper.java | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/server/capple/domain/boardComment/entity/BoardComment.java b/src/main/java/com/server/capple/domain/boardComment/entity/BoardComment.java index ce0fd6c8..e34576e5 100644 --- a/src/main/java/com/server/capple/domain/boardComment/entity/BoardComment.java +++ b/src/main/java/com/server/capple/domain/boardComment/entity/BoardComment.java @@ -29,14 +29,13 @@ public class BoardComment extends BaseEntity { @Column(nullable = false) private String content; - @Column(nullable = false) private Boolean isReport; public void update(String content) { this.content = content; } - public void submitReport() { this.isReport = true; } + public void submitReport() { this.isReport = Boolean.TRUE; } - public void cancelReport() { this.isReport = false; } + public void cancelReport() { this.isReport = Boolean.FALSE; } } diff --git a/src/main/java/com/server/capple/domain/boardComment/mapper/BoardCommentMapper.java b/src/main/java/com/server/capple/domain/boardComment/mapper/BoardCommentMapper.java index 9a73ff2b..470e8098 100644 --- a/src/main/java/com/server/capple/domain/boardComment/mapper/BoardCommentMapper.java +++ b/src/main/java/com/server/capple/domain/boardComment/mapper/BoardCommentMapper.java @@ -13,7 +13,7 @@ public BoardComment toBoardCommentEntity(Member member, Board board, String comm .member(member) .board(board) .content(comment) - .isReport(false) + .isReport(Boolean.FALSE) .build(); }