Skip to content

Commit

Permalink
🎨 #287 mapErrorMessageRes 간결하게
Browse files Browse the repository at this point in the history
  • Loading branch information
oreocube committed Sep 28, 2024
1 parent ae1be98 commit 2b47e90
Showing 1 changed file with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,8 @@ class InvitationCodeViewModel @Inject constructor(

private fun mapErrorMessageRes(e: Throwable): Int {
return when (e) {
is PicException.InvalidGroupCodeException -> {
R.string.enter_group_by_code_failure_not_found
}

is PicException.GroupOverflowException -> {
R.string.enter_group_by_code_failure_overflow
}

is PicException.InvalidGroupCodeException -> R.string.enter_group_by_code_failure_not_found
is PicException.GroupOverflowException -> R.string.enter_group_by_code_failure_overflow
else -> R.string.error_network
}
}
Expand Down

0 comments on commit 2b47e90

Please sign in to comment.