diff --git a/src/main/java/com/ripple/BE/post/dto/response/LikeCommentResponse.java b/src/main/java/com/ripple/BE/post/dto/response/LikeCommentResponse.java index 0ab1aae..d801e27 100644 --- a/src/main/java/com/ripple/BE/post/dto/response/LikeCommentResponse.java +++ b/src/main/java/com/ripple/BE/post/dto/response/LikeCommentResponse.java @@ -1,17 +1,17 @@ package com.ripple.BE.post.dto.response; +import com.ripple.BE.global.utils.RelativeTimeFormatter; import com.ripple.BE.post.domain.type.PostType; import com.ripple.BE.post.dto.LikeCommentDTO; -import java.time.LocalDateTime; public record LikeCommentResponse( - Long id, String content, String postName, PostType type, LocalDateTime createdDate) { + Long id, String content, String postName, PostType type, String createdDate) { public static LikeCommentResponse toLikeCommentResponse(LikeCommentDTO likeCommentDTO) { return new LikeCommentResponse( likeCommentDTO.id(), likeCommentDTO.content(), likeCommentDTO.postName(), likeCommentDTO.type(), - likeCommentDTO.createdDate()); + RelativeTimeFormatter.formatRelativeTime(likeCommentDTO.createdDate())); } }