Skip to content

Commit

Permalink
chore: 회원 에러 -> 장소 에러 수정 (#20)
Browse files Browse the repository at this point in the history
  • Loading branch information
gahyuun committed Jan 16, 2025
1 parent d51e9ce commit a72ad16
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public enum ErrorType {
/* Spot Error */
/* 400 Bad Request */
INVALID_DAY_ERROR(HttpStatus.BAD_REQUEST, 40099, "유효하지 않은 day입니다."),
;
NOT_FOUND_SPOT_ERROR(HttpStatus.NOT_FOUND, 40402, "유효한 장소가 없습니다");

private final HttpStatus httpStatus;
private final int code;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public class SpotService {
private final MenuRepository menuRepository;

public MenuListResponse fetchMenus(Long spotId) {
spotRepository.findById(spotId).orElseThrow(() -> new BusinessException(ErrorType.NOT_FOUND_MEMBER_ERROR));
spotRepository.findById(spotId).orElseThrow(() -> new BusinessException(ErrorType.NOT_FOUND_SPOT_ERROR));
List<MenuEntity> menuEntityList = menuRepository.findAllBySpotId(spotId);
List<MenuResponse> menuList = menuEntityList.stream()
.map(menu -> MenuResponse.builder().id(menu.getId()).name(menu.getName()).price(menu.getPrice())
Expand Down

0 comments on commit a72ad16

Please sign in to comment.