Skip to content

Commit

Permalink
fix: NPE 문제 해결
Browse files Browse the repository at this point in the history
  • Loading branch information
mikekks committed Dec 15, 2024
1 parent 7876015 commit c82df53
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package org.sopt.makers.crew.main.meeting.v2.dto.redis;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
Expand All @@ -26,7 +27,8 @@ public CoLeadersRedisDto(List<CoLeader> coLeaders) {
CoLeaderRedisDto coLeaderRedisDto = new CoLeaderRedisDto(coLeader.getUser().getId(),
coLeader.getUser().getOrgId(),
coLeader.getUser().getName(), coLeader.getUser().getProfileImage(), coLeader.getMeeting().getId());
List<CoLeaderRedisDto> coLeaderRedisDtos = coLeadersMap.get(coLeader.getMeeting().getId());
List<CoLeaderRedisDto> coLeaderRedisDtos = coLeadersMap.getOrDefault(coLeader.getMeeting().getId(),
new ArrayList<>());
coLeaderRedisDtos.add(coLeaderRedisDto);
coLeadersMap.put(coLeader.getMeeting().getId(), coLeaderRedisDtos);
});
Expand Down

0 comments on commit c82df53

Please sign in to comment.