@@ -33,13 +33,13 @@ internal data class HttpHeader(val key: String, val value: String)
33
33
internal data class HttpResponse (val responseCode : Int , val body : String , val headers : List <HttpHeader >)
34
34
35
35
internal class HttpConnection constructor(
36
- private val url : String ,
37
- private val method : HttpRequestMethod ,
38
- private val bodyMap : Map <* , * >? ,
39
- private val bodyString : String? ,
40
- contentType : String? ,
41
- private val headers : List <HttpHeader > = listOf(),
42
- val api : SpotifyApi <* , * >? = null
36
+ private val url : String ,
37
+ private val method : HttpRequestMethod ,
38
+ private val bodyMap : Map <* , * >? ,
39
+ private val bodyString : String? ,
40
+ contentType : String? ,
41
+ private val headers : List <HttpHeader > = listOf(),
42
+ val api : SpotifyApi <* , * >? = null
43
43
) {
44
44
private val contentType: ContentType = contentType?.let { ContentType .parse(it) } ? : ContentType .Application .Json
45
45
@@ -82,8 +82,8 @@ internal class HttpConnection constructor(
82
82
}
83
83
84
84
internal suspend fun execute (
85
- additionalHeaders : List <HttpHeader >? = null,
86
- retryIf502 : Boolean = true
85
+ additionalHeaders : List <HttpHeader >? = null,
86
+ retryIf502 : Boolean = true
87
87
): HttpResponse {
88
88
val httpRequest = buildRequest(additionalHeaders)
89
89
0 commit comments