-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
챌린지 응답 모델 변경, 챌린지 완료 Api 연동 #92
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생하셨습니다~!
challenge.accTime, | ||
challenge.badge.toBadge(), | ||
challenge.calorie, | ||
ChallengeType.getChallengeTypeByString(challenge.category ?: String.EMPTY), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit) 다음과 같이 줄여 볼 수 있을 것 같습니다!
ChallengeType.getChallengeTypeByString(challenge.category ?: String.EMPTY), | |
ChallengeType.getChallengeTypeByString(challenge.category.orEmpty()), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
!! orEmpty 좋네요! 코틀린에서 자체적으로 있는 메서드인가요?
@@ -55,7 +55,9 @@ fun ChallengeGoalContent( | |||
|
|||
val progressBarColor = challengeColor.progressBarColor | |||
|
|||
val progress = if (challenge.process == null) 0f else requireNotNull(challenge.process) / 100f | |||
val progress = | |||
if (challenge.progress == null) 0f else requireNotNull(challenge.progress) / 100f |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
코드 로직상 문제는 없지만 중복 null 체크 인 것 같아요!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
감사합니다!!
😎 작업 내용
🧐 변경된 내용
🥳 동작 화면
🤯 이슈 번호
🥲 비고