Skip to content

Commit 532e5ae

Browse files
committed
Fix[post]:gender enum
1 parent c23dee2 commit 532e5ae

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

backend/src/main/java/com/ai/lawyer/domain/poll/repository/PollVoteRepositoryImpl.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,8 @@ public List<PollStaticsDto> countStaticsByPollOptionIds(List<Long> pollOptionIds
9797
.fetch();
9898
return tuples.stream()
9999
.map(t -> {
100-
String gender = t.get(1, String.class);
100+
Member.Gender genderEnum = t.get(1, Member.Gender.class);
101+
String gender = genderEnum != null ? genderEnum.name() : "기타";
101102
Integer age = t.get(2, Integer.class);
102103
String ageGroup = getAgeGroup(age);
103104
Long voteCount = t.get(3, Long.class);

0 commit comments

Comments
 (0)