Skip to content

Commit

Permalink
#86 fix : authorized error code 변경
Browse files Browse the repository at this point in the history
Co-authored-by: yy0ung <[email protected]>
Co-authored-by: BENDENG1 <[email protected]>
  • Loading branch information
3 people committed Dec 12, 2023
1 parent f5b2fa2 commit 8dc8fd9
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Aos/app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ android {
minSdk = 24
targetSdk = 34
versionCode = 1
versionName = "1.0.1"
versionName = "1.0.3"

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
buildConfigField("String", "NAVER_LOGIN_CLIENT_ID", getProperty("naverLoginClientId"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ class BearerInterceptor @Inject constructor(
}

companion object {
const val TOKEN_ERROR = 401
const val TOKEN_ERROR = 403
const val AUTHORIZATION = "Authorization"
const val BEARER = "Bearer"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ suspend fun <T> runRemote(block: suspend () -> Response<T>): BaseState<T> {
} else {
val errorData = Gson().fromJson(response.errorBody()?.string(), BaseState.Error::class.java)
when(response.code()){
401 -> BaseState.Error(StatusCode.ERROR_AUTH, errorData.message)
403 -> BaseState.Error(StatusCode.ERROR_AUTH, errorData.message)
404 -> BaseState.Error(StatusCode.ERROR_NONE, errorData.message)
else -> BaseState.Error(StatusCode.ERROR, errorData.message)
}
Expand Down

0 comments on commit 8dc8fd9

Please sign in to comment.