Colton Idle
05/03/2025, 6:10 PMval response =
supabaseClient.functions.invoke("upload-image") {
setBody(
MultiPartFormDataContent(
formData {
append(
"file",
chosenPhoto!!,
Headers.build {
append(
HttpHeaders.ContentType,
"image/png"
)
append(
HttpHeaders.ContentDisposition,
"form-data; name=\"image\"; filename=\"upload.png\"",
)
})
}
)
)
contentType(ContentType.MultiPart.FormData)
}
in both cases. the upload completes successfully because i can see the result on the backend (uploads into a storage bucket) but I do actually get an error on the ios side.
🔴 HTTP request to https://myapp.supabase.co/functions/v1/upload-image (POST) failed with message: Content-Length mismatch: expected 434 bytes, but received 514 bytes
on Android. no error.Jan
05/03/2025, 6:12 PMJan
05/03/2025, 6:13 PMColton Idle
05/03/2025, 6:14 PMColton Idle
05/03/2025, 6:17 PMJan
05/03/2025, 6:24 PMFunctions#invoke()
Colton Idle
05/03/2025, 6:30 PMColton Idle
05/03/2025, 6:35 PM