From 02a4d1f1ea5d67511cc0cfbe236af9f676e9b223 Mon Sep 17 00:00:00 2001 From: Abdourahamane Boinaidi Date: Fri, 6 Dec 2024 10:37:29 +0100 Subject: [PATCH] fix: Resend email code with json body --- .../network/requests/UploadRequest.kt | 1 + 1 file changed, 1 insertion(+) diff --git a/STNetwork/src/commonMain/kotlin/com/infomaniak/multiplatform_swisstransfer/network/requests/UploadRequest.kt b/STNetwork/src/commonMain/kotlin/com/infomaniak/multiplatform_swisstransfer/network/requests/UploadRequest.kt index 5c87be63..9a7c0c41 100644 --- a/STNetwork/src/commonMain/kotlin/com/infomaniak/multiplatform_swisstransfer/network/requests/UploadRequest.kt +++ b/STNetwork/src/commonMain/kotlin/com/infomaniak/multiplatform_swisstransfer/network/requests/UploadRequest.kt @@ -49,6 +49,7 @@ internal class UploadRequest(json: Json, httpClient: HttpClient) : BaseRequest(j suspend fun resendEmailCode(resendEmailCodeBody: ResendEmailCodeBody): Boolean { val httpResponse = httpClient.post(url = createUrl(ApiRoutes.resendEmailCode)) { + contentType(ContentType.Application.Json) setBody(resendEmailCodeBody) } return httpResponse.status.isSuccess()