Vlad
05/31/2024, 11:41 AMAleksei Tirman [JB]
05/31/2024, 12:21 PMLogging
plugin is still installed. Otherwise, the track trace wouldn't contain that line.Vlad
05/31/2024, 12:22 PMAleksei Tirman [JB]
05/31/2024, 1:41 PMVlad
05/31/2024, 1:44 PMfun createHttpClient(json: Json, baseUrl: String): HttpClient {
return HttpClient {
install(ContentNegotiation) {
json(json)
}
// This crashes some iOS devices when we download big files
// if (BuildUtils.isDevelopmentEnvironment) {
// install(Logging) {
// logger = Logger.DEFAULT
// level = LogLevel.ALL
// }
// }
defaultRequest {
url(baseUrl)
with (headers) {
append(name = "X-Client-Type", value = "xx")
append(name = "X-Client-Version", value = "yy")
}
}
}
}
implementation(libs.ktor.client.core)
implementation(libs.ktor.client.content.negotiation)
implementation(libs.ktor.client.auth)
// implementation(libs.ktor.client.logging)
Whelp, but the line is there