From fdbcd74de5f862bbb6c446aadee5e566598bf4b7 Mon Sep 17 00:00:00 2001 From: dldmldlsy Date: Sun, 28 Jan 2024 21:28:40 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EC=B1=84=ED=8C=85=20=EC=9E=91=EC=84=B1?= =?UTF-8?q?=20=EC=8B=9C=EA=B0=84=20=ED=95=9C=EA=B5=AD=EC=8B=9C=EA=B0=84?= =?UTF-8?q?=EC=9C=BC=EB=A1=9C=20=EB=B3=80=ED=99=98=20=EB=A1=9C=EC=A7=81=20?= =?UTF-8?q?=EC=98=A4=EB=A5=98=20=ED=95=B4=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../goldenticket/domain/chat/service/ChatService.java | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/main/java/site/goldenticket/domain/chat/service/ChatService.java b/src/main/java/site/goldenticket/domain/chat/service/ChatService.java index d2971a59..2fb534d7 100644 --- a/src/main/java/site/goldenticket/domain/chat/service/ChatService.java +++ b/src/main/java/site/goldenticket/domain/chat/service/ChatService.java @@ -13,10 +13,6 @@ import static site.goldenticket.common.response.ErrorCode.USER_NOT_FOUND; import java.time.LocalDate; -import java.time.LocalDateTime; -import java.time.ZoneId; -import java.time.ZonedDateTime; -import java.time.format.DateTimeFormatter; import java.time.temporal.ChronoUnit; import java.util.ArrayList; import java.util.Collections; @@ -326,15 +322,12 @@ public ChatRoomDetailResponse getChatRoomDetail(Long userId, Long chatRoomId) { chat.setViewedByBuyer(true); } chatRepository.save(chat); // *확인 필요 - ZoneId koreaZoneId = ZoneId.of("Asia/Seoul"); - ZonedDateTime koreaZonedDateTime = chat.getCreatedAt().atZone(koreaZoneId); - LocalDateTime koreaLocalDateTime = koreaZonedDateTime.toLocalDateTime(); ChatResponse chatResponse = ChatResponse.builder() .chatId(chat.getId()) .senderType(chat.getSenderType()) .userId(chat.getUserId()) .content(chat.getContent()) - .createdAt(koreaLocalDateTime) + .createdAt(chat.getCreatedAt().plusHours(9)) .viewed(true) .build(); chatResponseList.add(chatResponse);