From a5827f9136fdd5241dfaaf7eec8404c59533a69c Mon Sep 17 00:00:00 2001 From: "Developer @ Loverde Company" Date: Fri, 11 Sep 2026 09:02:17 -0300 Subject: [PATCH] fix: update performLCERequest for LCEssentials 2.0.2 API.request signature LCEssentials 2.0.2 replaced request(url:params:method:headers:jsonEncoding:debug:) with request(url:method:body:pathParams:headers:debug:timeoutInterval:networkServiceType:persistConnection:). The pre-encoded params Data is now wrapped in RawBody to preserve the same application/json Content-Type behavior that jsonEncoding: true used to set. --- PediFoods/Services/ApiClient.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PediFoods/Services/ApiClient.swift b/PediFoods/Services/ApiClient.swift index cfc38c9..7e0c577 100644 --- a/PediFoods/Services/ApiClient.swift +++ b/PediFoods/Services/ApiClient.swift @@ -175,12 +175,12 @@ extension ApiClient { headers: [String: String] ) async throws -> String { let httpMethod = toHTTPMethod(method) + let body: (any HTTPBody)? = params.map { RawBody(data: $0, contentType: "application/json; charset=UTF-8") } return try await API.shared.request( url: url, - params: params, method: httpMethod, + body: body, headers: headers, - jsonEncoding: true, debug: true ) }