Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ extension Transaction {
}

case .executing(let context, let requestStreamState, .finished):
// an error occured after full response received, but before the full request was sent
// an error occurred after full response received, but before the full request was sent
self.state = .finished(error: error)
switch requestStreamState {
case .paused(let bodyStreamContinuation):
Expand Down
2 changes: 1 addition & 1 deletion Sources/AsyncHTTPClient/HTTPHandler.swift
Original file line number Diff line number Diff line change
Expand Up @@ -802,7 +802,7 @@ public protocol HTTPClientResponseDelegate: AnyObject, Sendable {
///
/// - parameters:
/// - task: Current request context.
/// - error: Error that occured during response processing.
/// - error: Error that occurred during response processing.
func didReceiveError(task: HTTPClient.Task<Response>, _ error: Error)

/// Called when the complete HTTP request is finished. You must return an instance of your ``Response`` associated type. Will be called once, except if an error occurred.
Expand Down
4 changes: 2 additions & 2 deletions Sources/AsyncHTTPClient/RequestBag+StateMachine.swift
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ extension RequestBag {
case queued(HTTPRequestScheduler, RedirectHandler<Delegate.Response>?)
/// if the deadline was exceeded while in the `.queued(_:)` state,
/// we wait until the request pool fails the request with a potential more descriptive error message,
/// if a connection failure has occured while the request was queued.
/// if a connection failure has occurred while the request was queued.
case deadlineExceededWhileQueued
case executing(HTTPRequestExecutor, RequestStreamState, ResponseStreamState)
case finished(error: Error?)
Expand Down Expand Up @@ -545,7 +545,7 @@ extension RequestBag.StateMachine {

case .finished(error: .none):
preconditionFailure(
"Invalid state... If no error occured, this must not be called, after the request was finished"
"Invalid state... If no error occurred, this must not be called, after the request was finished"
)

case .modifying:
Expand Down