본문 바로가기

Java Spring Boot

에러 메시지 띄울 때, CustomException 사용

에러 메시지 띄울 때, 아래와 같이 사용.

if (churchName == null) {
      throw new CustomException(ErrorMessage.MEMBER_NOT_FOUND);
    }