Skip to content

Commit

Permalink
Merge pull request #272 from Modagbul/hotfix
Browse files Browse the repository at this point in the history
hotfix : 레벨 70 이상 목표보드 에러
  • Loading branch information
seungueonn authored Mar 18, 2024
2 parents ea6fa8b + 91f6f20 commit f707f7e
Showing 1 changed file with 12 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,19 @@ public class TeamScoreGetUseCase {
public TeamScoreRes getTeamScoreInfo(Long teamId) {

TeamScore teamScore = teamScoreQueryService.findTeamScoreByTeam(teamId);
Long level = teamScore.getLevel();
Long score = teamScore.getScore();

// 70 레벨 이상은 경험치 120 되어야 레벨업 가능. level을 각 레벨 별 필요한 경험치 수에 따르 퍼센트로 계산
if (level > 70) {
score = ( score / 120 ) * 100;
}

return TeamScoreRes.builder()
.score(teamScore.getScore())
.level(teamScore.getLevel())
.build()
;
.score(score)
.level(level)
.build();

}

}

0 comments on commit f707f7e

Please sign in to comment.