Skip to content

Commit

Permalink
refactor: 본인 게시글 까지 조회 되게 변경 (#43)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jiwon-cho authored Feb 24, 2024
1 parent 46f46ff commit f7c439b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main/kotlin/mara/server/domain/share/ShareRepository.kt
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ class CustomShareRepositoryImpl(
override fun findAllMyFriendsShare(pageable: Pageable, status: ShareStatus, user: User): Page<Share> {
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 ->
Expand Down

0 comments on commit f7c439b

Please sign in to comment.