Skip to content

Commit

Permalink
[REFACTOR] 행사일 때 출석 상태 반환 로직 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
KWY0218 committed Apr 10, 2024
1 parent 8abf1d4 commit e25492f
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,13 +86,12 @@ public AttendanceStatus getStatus() {
val second = getSubAttendanceByRound(2);

return switch (this.lecture.getAttribute()) {
case SEMINAR -> {
case SEMINAR, EVENT -> {
if (first.getStatus().equals(ATTENDANCE) && second.getStatus().equals(ATTENDANCE)) {
yield ATTENDANCE;
}
yield first.getStatus().equals(ABSENT) && second.getStatus().equals(ABSENT) ? ABSENT : TARDY;
}
case EVENT -> second.getStatus().equals(ATTENDANCE) ? ATTENDANCE : ABSENT;
case ETC -> second.getStatus().equals(ATTENDANCE) ? PARTICIPATE : NOT_PARTICIPATE;
};
}
Expand Down

0 comments on commit e25492f

Please sign in to comment.