Skip to content

Commit

Permalink
merge: question set response 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
rlaisqls authored Nov 17, 2023
2 parents 63107f8 + 473515d commit f99ea90
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,8 @@ data class GetQuestionSetDetailResponse(
val isDisliked: Boolean,
val isFavorite: Boolean,
val tags: List<String>,
val comments: List<CommentResponse>
val comments: List<CommentResponse>,
val questionIdList: List<Long>
) {
companion object {
fun of(questionSetDetail: QuestionSetDetailDto, questionList: List<Questions>, user: User) = questionSetDetail.run {
Expand Down Expand Up @@ -359,7 +360,8 @@ data class GetQuestionSetDetailResponse(
comments = commentList.distinct().map { CommentResponse.of(
comments = it,
isOwner = writerId == user.id || it.writer.id == user.id
) }
) },
questionIdList = questionList.map{questions -> questions.id }
)
}
}
Expand Down

0 comments on commit f99ea90

Please sign in to comment.