Skip to content

Commit

Permalink
Merge pull request #35 from kusitms-28th-Meetup-E/hotfix
Browse files Browse the repository at this point in the history
fix : subscribe
  • Loading branch information
eojinny authored Nov 23, 2023
2 parents 8c731f6 + 42b11de commit d2d6819
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ public class Member {
private String birth;
private String gender;

// @OneToMany(fetch = FetchType.LAZY)
// private List<Subscribe> subscribeList = new ArrayList<>();
@OneToMany(fetch = FetchType.LAZY)
private List<Subscribe> subscribeList = new ArrayList<>();

public void signUp(SignUpRequest signUpRequest) {
this.nickname = signUpRequest.getNickname();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ public SubscribeRes unSubscribe(String socialId, Long topicId, Long issueId) {
Member member = memberQueryService.getMemberBySocialId(socialId);
Subscribe subscribe = subscribeQueryService.findSubscribeByMemberAndTopic(member, topicId,issueId);
subscribeDeleteService.delete(subscribe);
member.getSubscribeList().remove(subscribe);
return subscribeMapper.mapToSubscribeRes(subscribe).setUnScribe(subscribeQueryService.getSubscribers(issueId));
}
}

0 comments on commit d2d6819

Please sign in to comment.