From ddb87be6a8d637f981bc59ebe6ebd4c7a5cb6938 Mon Sep 17 00:00:00 2001 From: Jeongho Date: Wed, 22 May 2024 23:19:31 +0900 Subject: [PATCH] =?UTF-8?q?Fix:=20=EB=A9=94=EC=9D=B8=ED=8E=98=EC=9D=B4?= =?UTF-8?q?=EC=A7=80=20=EC=B6=94=EC=B2=9C=ED=99=9C=EB=8F=99=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../backend/domain/activity/service/ActivityService.java | 6 ++++-- .../teame/backend/domain/user/service/UserService.java | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/meetup/teame/backend/domain/activity/service/ActivityService.java b/src/main/java/com/meetup/teame/backend/domain/activity/service/ActivityService.java index e31f685..c932b7b 100644 --- a/src/main/java/com/meetup/teame/backend/domain/activity/service/ActivityService.java +++ b/src/main/java/com/meetup/teame/backend/domain/activity/service/ActivityService.java @@ -42,7 +42,6 @@ public class ActivityService { //특정 활동 상제 정보 response dto화 public ActivityDetailsRes getActivityDetails(Long activityId) { Activity activity = findActivityById(activityId); - //List imageUrls = getImageUrls(activity); return ActivityDetailsRes.of(activity); } @@ -54,7 +53,10 @@ private Activity findActivityById(Long activityId) { //활동 목록 필터링으로 조회 public ReadActivitiesRes findActivities(ReadActivitiesReq activitiesReq) { - Long userId = SecurityContextProvider.getAuthenticatedUserId(); + Long userId = 50L; + if (!SecurityContextProvider.isAnonymousUser()) { + userId = SecurityContextProvider.getAuthenticatedUserId(); + } long page = activitiesReq.getPage(); long offset = page * ACTIVITY_PAGE_SIZE; long limit = ACTIVITY_PAGE_SIZE; diff --git a/src/main/java/com/meetup/teame/backend/domain/user/service/UserService.java b/src/main/java/com/meetup/teame/backend/domain/user/service/UserService.java index d2da83a..b27df17 100644 --- a/src/main/java/com/meetup/teame/backend/domain/user/service/UserService.java +++ b/src/main/java/com/meetup/teame/backend/domain/user/service/UserService.java @@ -49,7 +49,7 @@ public class UserService { private final ActivityLikeRepository activityLikeRepository; public ReadMainRes readMainPage() { - Long userId = 5L; + Long userId = 50L; if(!SecurityContextProvider.isAnonymousUser()) userId = SecurityContextProvider.getAuthenticatedUserId(); User user = userRepository.findById(userId)