Skip to content

Commit

Permalink
Merge pull request #89 from Begin-Vegan/develop
Browse files Browse the repository at this point in the history
[DEPLOY]: 배포
  • Loading branch information
phonil authored Jul 28, 2024
2 parents 8e27b58 + ace22a9 commit 7999586
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -371,6 +371,11 @@ public ResponseEntity<?> findRandomRestaurantWithPermission(UserPrincipal userPr
}
}
if (!restaurantResList.isEmpty()) {
if (count - restaurantResList.size() >= 0) { // 10km 내 식당 3개 미만
randomRestaurantResList.addAll(restaurantResList);
count -= restaurantResList.size();
}

// 랜덤 수 count개(3개) 추리기
Set<Integer> randomNum = new HashSet<>();
while(randomNum.size() < count){
Expand Down

0 comments on commit 7999586

Please sign in to comment.