Skip to content

Commit

Permalink
CR changes
Browse files Browse the repository at this point in the history
  • Loading branch information
emildzwonek committed Aug 2, 2024
1 parent e7eb4d7 commit e62bd32
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/URLSessionDecodable/URLSessionDecodable.swift
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ extension URLSession {
method: HTTPMethod,
parameters: ParametersEncoding?,
headers: HTTPHeaders?,
decoder: @autoclosure @escaping @Sendable () -> DataDecoder
decoder: @autoclosure @Sendable () -> DataDecoder
) async throws -> T {
let request = self.request(with: url, method: method, parameters: parameters, headers: headers)
let (data, response) = try await data(for: request)
Expand All @@ -76,7 +76,7 @@ extension URLSession {
private static func handle<T: Decodable>(
response: HTTPURLResponse,
data: Data,
decoder: @autoclosure @escaping @Sendable () -> DataDecoder,
decoder: @autoclosure @Sendable () -> DataDecoder,
url: URL
) -> Result<T, URLSessionDecodableError> {
guard 200..<300 ~= response.statusCode else {
Expand Down

0 comments on commit e62bd32

Please sign in to comment.