Skip to content

Commit

Permalink
[FIX] 변수 삭제 및 Member 조회 method 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
unanchoi committed Oct 18, 2023
1 parent fd6f18a commit 57ab15f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/main/java/com/smeme/server/service/MemberService.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
import java.util.List;
import java.util.stream.Collectors;

import static com.smeme.server.util.message.ErrorMessage.INVALID_MEMBER;
import static java.util.Objects.isNull;
import static java.util.Objects.nonNull;

Expand All @@ -40,7 +39,6 @@ public class MemberService {
private final MemberBadgeService memberBadgeService;

private final ValueConfig valueConfig;
private Member member;

@Transactional
public MemberUpdateResponseDTO updateMember(Long memberId, MemberUpdateRequestDTO request) {
Expand Down Expand Up @@ -107,7 +105,8 @@ public MemberNameResponseDTO checkDuplicatedName(String name) {
}

protected Member get(Long id) {
return member;
return memberRepository.findById(id)
.orElseThrow(() -> new EntityNotFoundException(ErrorMessage.EMPTY_MEMBER.getMessage()));
}

private void updateTrainingTime(Member member, MemberPlanUpdateRequestDTO request) {
Expand Down

0 comments on commit 57ab15f

Please sign in to comment.