Skip to content

Commit

Permalink
Fix: completeDto isSuccessed 계산 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
nampongo committed Apr 14, 2024
1 parent d4f92f2 commit c711040
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public class MyChallengeCompletedDto extends MyChallengeResponseDto {
public static MyChallengeCompletedDto of(MyChallenge myChallenge, ChallengeGroup group, Challenge challenge) {
long days = ChronoUnit.DAYS.between(group.getStartDate(), group.getEndDate());
int successCount = days > 10 ? 10 : 5;
Boolean isSuccessed = myChallenge.getSuccessCount() > successCount ? true : false;
Boolean isSuccessed = myChallenge.getSuccessCount() < successCount ? false : true;
return MyChallengeCompletedDto.builder()
.groupTitle(group.getGroupTitle())
.startDate(group.getStartDate().plusHours(9))
Expand Down

0 comments on commit c711040

Please sign in to comment.