Skip to content

Commit

Permalink
Merge pull request #15 from kusitms-28th-Meetup-E/feat/search
Browse files Browse the repository at this point in the history
feat: Search API
  • Loading branch information
eojinny authored Nov 22, 2023
2 parents 0e851f9 + 858708d commit 3867125
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,14 @@ public List<CommunityRes> getCommunityByMyId(String memberId) {

public SearchRes search(String memberId, CommunityOrderCondition communityOrderCondition, String keyword) {
List<CommunityRes> searchResults = communityRepository.getSearchCommunity(memberId,communityOrderCondition,keyword).orElseThrow(NotFoundCommunityException::new);;

searchResults.stream().forEach(
communityRes1 ->
{
String writerId = communityRes1.getWriterId();
MemberDto memberDto = findMemberFeignClient.getMemberBySocialId(writerId);
communityRes1.updateMemberDto(memberDto);
}
);

SearchRes searchRes = new SearchRes();
searchRes.setSearchKeyword(keyword);
Expand Down

0 comments on commit 3867125

Please sign in to comment.