Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Fix/98] 회원가입 로직 수정 #106

Merged
merged 5 commits into from
Aug 2, 2024
Merged

[Fix/98] 회원가입 로직 수정 #106

merged 5 commits into from
Aug 2, 2024

Conversation

rimi3226
Copy link
Contributor

@rimi3226 rimi3226 commented Aug 2, 2024

🚀 개요

회원가입 로직 수정

🔍 변경사항

  • /v1/member/riot 은 해당 계정이 riot에 실제로 있는지 확인하는 용도
  • /v1/member/join 에서 riot 계정 연동되도록 수정 -> 중간에 에러 발생할 경우 DB에 데이터 안들어감
  • riotService에서 처리하던 메소드들을 riotUtil로 변경

⏳ 작업 내용

  • /v1/member/riot 로직 수정
  • /v1/member/join 에서 riot 연동되도록 설정
  • /v1/member/join 에서 return 값으로 member 정보 반환
  • /** 붙이기

📝 논의사항

Copy link
Member

@Eunjin3395 Eunjin3395 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다!

@@ -32,8 +33,10 @@ public void setMember(Member member) {
this.member.getMemberChampionList().remove(this);
}
this.member = member;
if (this.member.getMemberChampionList() == null) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

혹시 여기에서 이 조건을 추가하신 이유가 있으신가요?
@OneToMany(mappedBy = "member", cascade = CascadeType.ALL) private List<MemberChampion> memberChampionList = new ArrayList<>();
member 엔티티에서 이렇게 초기화를 해 주어서 저는 memberChampionList가 null인 경우가 없을 거라고 생각했었는데 혹시 이 조건+코드가 없으면 뭔가 오류가 나는건지 궁금합니다..!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

네ㅠㅠ 이상하게 @onetomany를 했음에도 불구하고 이런 에러가 발생하더라구요..
Cannot invoke "java.util.List.add(Object)" because the return value of "com.gamegoo.domain.Member.getMemberChampionList()" is null
그래서 추가했습니다!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

헉 그렇군요...... ㅠㅠㅠㅠ 왜 그런건지 제가 나중에 따로 찾아보겠습니다.. 그럼 이대로 머지해주시면 될 것 같아요 !!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

넵 감사합니다!

Copy link
Contributor

@hzee97 hzee97 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다!

@rimi3226 rimi3226 merged commit 93a57b6 into develop Aug 2, 2024
@rimi3226 rimi3226 deleted the fix/98 branch August 2, 2024 23:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants