Skip to content

Commit 25a81bc

Browse files
authored
fix(foundation): Fixed crash in URLSession.data(for:) (#17)
1 parent 4302be8 commit 25a81bc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/SimpleHTTPFoundation/Foundation/URLSession+Publisher.swift renamed to Sources/SimpleHTTPFoundation/Foundation/URLSession+Async.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ extension URLSession {
66
try await withCheckedThrowingContinuation { promise in
77
self.dataTask(with: urlRequest) { data, response, error in
88
if let error = error {
9-
promise.resume(throwing: error)
9+
return promise.resume(throwing: error)
1010
}
1111

1212
guard let data = data, let response = response else {

0 commit comments

Comments
 (0)