From f7c439bdd6161967bd8bdc5cec9baedbd999456b Mon Sep 17 00:00:00 2001 From: Cho jiwon <77895305+Jiwon-cho@users.noreply.github.com> Date: Sat, 24 Feb 2024 12:58:55 +0900 Subject: [PATCH] =?UTF-8?q?refactor:=20=EB=B3=B8=EC=9D=B8=20=EA=B2=8C?= =?UTF-8?q?=EC=8B=9C=EA=B8=80=20=EA=B9=8C=EC=A7=80=20=EC=A1=B0=ED=9A=8C=20?= =?UTF-8?q?=EB=90=98=EA=B2=8C=20=EB=B3=80=EA=B2=BD=20(#43)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/kotlin/mara/server/domain/share/ShareRepository.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/kotlin/mara/server/domain/share/ShareRepository.kt b/src/main/kotlin/mara/server/domain/share/ShareRepository.kt index 247dfd7..391d6ff 100644 --- a/src/main/kotlin/mara/server/domain/share/ShareRepository.kt +++ b/src/main/kotlin/mara/server/domain/share/ShareRepository.kt @@ -33,7 +33,9 @@ class CustomShareRepositoryImpl( override fun findAllMyFriendsShare(pageable: Pageable, status: ShareStatus, user: User): Page { val friendsList = queryFactory.select(friendship.toUser.userId) .from(friendship) - .where(friendship.fromUser.eq(user)) + .where(friendship.fromUser.eq(user)).fetch() + + friendsList.add(user.userId) var sortBy = registeredDate pageable.sort.forEach { order ->