Skip to content
This repository was archived by the owner on Sep 15, 2025. It is now read-only.

Commit 299bf23

Browse files
committed
Rename parameter fulfillingProgress: Progress to fulfilling: Progress
1 parent dbf094c commit 299bf23

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

WordPressKit/HTTPClient.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ extension URLSession {
4444
func perform<E: LocalizedError>(
4545
request builder: HTTPRequestBuilder,
4646
acceptableStatusCodes: [ClosedRange<Int>] = [200...299],
47-
fulfillingProgress parentProgress: Progress? = nil,
47+
fulfilling parentProgress: Progress? = nil,
4848
errorType: E.Type = E.self
4949
) async -> WordPressAPIResult<HTTPAPIResponse<Data>, E> {
5050
if let parentProgress {

WordPressKitTests/Utilities/URLSessionHelperTests.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ class URLSessionHelperTests: XCTestCase {
116116
XCTAssertEqual(progress.completedUnitCount, 0)
117117
XCTAssertEqual(progress.fractionCompleted, 0)
118118

119-
let _ = await URLSession.shared.perform(request: .init(url: URL(string: "https://wordpress.org/hello")!), fulfillingProgress: progress, errorType: TestError.self)
119+
let _ = await URLSession.shared.perform(request: .init(url: URL(string: "https://wordpress.org/hello")!), fulfilling: progress, errorType: TestError.self)
120120
XCTAssertEqual(progress.completedUnitCount, 20)
121121
XCTAssertEqual(progress.fractionCompleted, 1)
122122
}
@@ -136,7 +136,7 @@ class URLSessionHelperTests: XCTestCase {
136136
}
137137

138138
// The result should be an cancellation result
139-
let result = await URLSession.shared.perform(request: .init(url: URL(string: "https://wordpress.org/hello")!), fulfillingProgress: progress, errorType: TestError.self)
139+
let result = await URLSession.shared.perform(request: .init(url: URL(string: "https://wordpress.org/hello")!), fulfilling: progress, errorType: TestError.self)
140140
if case let .failure(.connection(urlError)) = result, urlError.code == .cancelled {
141141
// Do nothing
142142
} else {

0 commit comments

Comments
 (0)