Skip to content

Commit

Permalink
검색 빈칸 에러 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
HyungJu committed Sep 21, 2024
1 parent 737586b commit 0c3a833
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ class TourAreaController(
@RequestBody request: TourAreaSearchRequest,
pageable: Pageable
): BaseResponse<Page<TourAreaResponseDto>> {

val tourAreas = tourAreaService.search(request, pageable)
val likes = likeService.getAllLikedTourAreaIdsByMember(memberId)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ class TripController(

@PostMapping("/trip/search")
fun getSearchResponse(@RequestBody keywordRequest: KeywordRequest): BaseResponse<List<SearchedResponse>> {
if(keywordRequest.keyword.isEmpty()) {
return BaseResponse.success(emptyList())
}
val result = tripSearchService.searchByKeyword(keywordRequest.keyword)
return BaseResponse.success(result)
}
Expand Down

0 comments on commit 0c3a833

Please sign in to comment.