Skip to content

Commit 08feca7

Browse files
committed
[#228] Remove redundant line and refactor code format
1 parent c79ef76 commit 08feca7

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

template-xml/app/src/main/java/co/nimblehq/template/xml/di/modules/RetrofitModule.kt

+1-3
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ class RetrofitModule {
4040
fun provideApiService(retrofit: Retrofit): ApiService =
4141
ApiServiceProvider.getApiService(retrofit)
4242

43-
4443
@Authenticate
4544
@Provides
4645
fun provideAuthRetrofit(
@@ -54,6 +53,5 @@ class RetrofitModule {
5453
@Provides
5554
fun provideAuthService(
5655
@Authenticate retrofit: Retrofit
57-
): AuthService =
58-
ApiServiceProvider.getAuthService(retrofit)
56+
): AuthService = ApiServiceProvider.getAuthService(retrofit)
5957
}

template-xml/data/src/main/java/co/nimblehq/template/xml/data/service/authenticator/ApplicationRequestAuthenticator.kt

+2-3
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ import kotlinx.coroutines.flow.last
1010
import okhttp3.*
1111

1212
const val REQUEST_HEADER_AUTHORIZATION = "Authorization"
13+
const val HEADER_AUTHENTICATION_SKIPPING_ERROR_TYPE = "Authentication-Skipping-ErrorType"
14+
private const val MAX_ATTEMPTS = 3
1315

1416
class ApplicationRequestAuthenticator(
1517
private val tokenRefresher: TokenRefresher,
@@ -88,6 +90,3 @@ class ApplicationRequestAuthenticator(
8890
return false
8991
}
9092
}
91-
92-
const val HEADER_AUTHENTICATION_SKIPPING_ERROR_TYPE = "Authentication-Skipping-ErrorType"
93-
private const val MAX_ATTEMPTS = 3

0 commit comments

Comments
 (0)