diff --git a/feed-domain/src/main/java/com/xquare/v1servicefeed/comment/Comment.java b/feed-domain/src/main/java/com/xquare/v1servicefeed/comment/Comment.java index 59668d6d..dfeb760e 100644 --- a/feed-domain/src/main/java/com/xquare/v1servicefeed/comment/Comment.java +++ b/feed-domain/src/main/java/com/xquare/v1servicefeed/comment/Comment.java @@ -24,5 +24,5 @@ public class Comment { private final LocalDateTime updatedAt; - private final Boolean isDeleted = false; + private final boolean isDeleted; } diff --git a/feed-domain/src/main/java/com/xquare/v1servicefeed/comment/api/impl/CommentApiImpl.java b/feed-domain/src/main/java/com/xquare/v1servicefeed/comment/api/impl/CommentApiImpl.java index b5a4d9d1..5452af7a 100644 --- a/feed-domain/src/main/java/com/xquare/v1servicefeed/comment/api/impl/CommentApiImpl.java +++ b/feed-domain/src/main/java/com/xquare/v1servicefeed/comment/api/impl/CommentApiImpl.java @@ -53,6 +53,7 @@ public void saveComment(CreateCommentDomainRequest request) { .userId(userId) .createAt(LocalDateTime.now()) .updatedAt(LocalDateTime.now()) + .isDeleted(false) .build() ); diff --git a/feed-domain/src/main/java/com/xquare/v1servicefeed/feed/Feed.java b/feed-domain/src/main/java/com/xquare/v1servicefeed/feed/Feed.java index 60913ed5..92abcc94 100644 --- a/feed-domain/src/main/java/com/xquare/v1servicefeed/feed/Feed.java +++ b/feed-domain/src/main/java/com/xquare/v1servicefeed/feed/Feed.java @@ -28,5 +28,5 @@ public class Feed { private final Integer commentCount; - private final Boolean isDeleted = false; + private final boolean isDeleted; } diff --git a/feed-domain/src/main/java/com/xquare/v1servicefeed/feed/api/impl/FeedApiImpl.java b/feed-domain/src/main/java/com/xquare/v1servicefeed/feed/api/impl/FeedApiImpl.java index 59403f46..b9f490b2 100644 --- a/feed-domain/src/main/java/com/xquare/v1servicefeed/feed/api/impl/FeedApiImpl.java +++ b/feed-domain/src/main/java/com/xquare/v1servicefeed/feed/api/impl/FeedApiImpl.java @@ -38,7 +38,6 @@ public class FeedApiImpl implements FeedApi { private final CommandFeedSpi commandFeedSpi; private final FeedUserSpi feedUserSpi; - private final CommandCommentSpi commandCommentSpi; private final CommandFeedImageSpi commandFeedImageSpi; private final SecuritySpi securitySpi; private final QueryFeedSpi queryFeedSpi; @@ -67,6 +66,7 @@ public SaveFeedResponse saveFeed(DomainCreateFeedRequest request) { .categoryId(request.getCategoryId()) .userId(securitySpi.getCurrentUserId()) .authorityType(request.getAuthorityType()) + .isDeleted(false) .build(); UUID feedId = commandFeedSpi.saveFeed(feed); diff --git a/feed-infrastructure/src/main/java/com/xquare/v1servicefeed/comment/domain/CommentEntity.java b/feed-infrastructure/src/main/java/com/xquare/v1servicefeed/comment/domain/CommentEntity.java index 54985d45..940b65e7 100644 --- a/feed-infrastructure/src/main/java/com/xquare/v1servicefeed/comment/domain/CommentEntity.java +++ b/feed-infrastructure/src/main/java/com/xquare/v1servicefeed/comment/domain/CommentEntity.java @@ -37,7 +37,7 @@ public class CommentEntity extends BaseUUIDEntity { private LocalDateTime updatedAt; @Column(columnDefinition = "BIT(1) default 0", nullable = false) - private Boolean isDeleted; + private boolean isDeleted; public CommentEntity updateComment(String content) { this.content = content; @@ -45,7 +45,7 @@ public CommentEntity updateComment(String content) { return this; } - public void updatedIsDeleted(Boolean isDeleted) { + public void updatedIsDeleted(boolean isDeleted) { this.isDeleted = isDeleted; } } diff --git a/feed-infrastructure/src/main/java/com/xquare/v1servicefeed/feed/domain/FeedEntity.java b/feed-infrastructure/src/main/java/com/xquare/v1servicefeed/feed/domain/FeedEntity.java index 10dc444d..43b78d62 100644 --- a/feed-infrastructure/src/main/java/com/xquare/v1servicefeed/feed/domain/FeedEntity.java +++ b/feed-infrastructure/src/main/java/com/xquare/v1servicefeed/feed/domain/FeedEntity.java @@ -43,7 +43,7 @@ public class FeedEntity extends BaseUUIDEntity { private String authorityType; @Column(columnDefinition = "BIT(1) default 0", nullable = false) - private Boolean isDeleted; + private boolean isDeleted; @OneToMany(mappedBy = "feedEntity") private Set feedImageEntities; @@ -53,7 +53,7 @@ public void updateFeedContent(String title, String content) { this.content = content; } - public void updateIsDeleted(Boolean isDeleted) { + public void updateIsDeleted(boolean isDeleted) { this.isDeleted = isDeleted; } }