Skip to content

Commit 77ffedf

Browse files
committed
Fix formatting
1 parent fec1b80 commit 77ffedf

File tree

2 files changed

+8
-18
lines changed

2 files changed

+8
-18
lines changed

Sources/AsyncHTTPClient/ConnectionPool/HTTPConnectionPool+Factory.swift

+2-6
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,7 @@ extension HTTPConnectionPool.ConnectionFactory {
8585
logger: logger
8686
)
8787

88-
if let connectionDebugInitializer
89-
= self.clientConfiguration.http1_1ConnectionDebugInitializer
90-
{
88+
if let connectionDebugInitializer = self.clientConfiguration.http1_1ConnectionDebugInitializer {
9189
connectionDebugInitializer(channel).whenComplete { debugInitializerResult in
9290
switch debugInitializerResult {
9391
case .success:
@@ -115,9 +113,7 @@ extension HTTPConnectionPool.ConnectionFactory {
115113
).whenComplete { result in
116114
switch result {
117115
case .success((let connection, let maximumStreams)):
118-
if let connectionDebugInitializer
119-
= self.clientConfiguration.http2ConnectionDebugInitializer
120-
{
116+
if let connectionDebugInitializer = self.clientConfiguration.http2ConnectionDebugInitializer {
121117
connectionDebugInitializer(channel).whenComplete {
122118
debugInitializerResult in
123119
switch debugInitializerResult {

Sources/AsyncHTTPClient/HTTPClient.swift

+6-12
Original file line numberDiff line numberDiff line change
@@ -848,16 +848,13 @@ public class HTTPClient {
848848
public var enableMultipath: Bool
849849

850850
/// A method with access to the HTTP/1 connection channel that is called when creating the connection.
851-
public var http1_1ConnectionDebugInitializer:
852-
(@Sendable (Channel) -> EventLoopFuture<Void>)?
851+
public var http1_1ConnectionDebugInitializer: (@Sendable (Channel) -> EventLoopFuture<Void>)?
853852

854853
/// A method with access to the HTTP/2 connection channel that is called when creating the connection.
855-
public var http2ConnectionDebugInitializer:
856-
(@Sendable (Channel) -> EventLoopFuture<Void>)?
854+
public var http2ConnectionDebugInitializer: (@Sendable (Channel) -> EventLoopFuture<Void>)?
857855

858856
/// A method with access to the HTTP/2 stream channel that is called when creating the stream.
859-
public var http2StreamChannelDebugInitializer:
860-
(@Sendable (Channel) -> EventLoopFuture<Void>)?
857+
public var http2StreamChannelDebugInitializer: (@Sendable (Channel) -> EventLoopFuture<Void>)?
861858

862859
public init(
863860
tlsConfiguration: TLSConfiguration? = nil,
@@ -970,12 +967,9 @@ public class HTTPClient {
970967
proxy: Proxy? = nil,
971968
ignoreUncleanSSLShutdown: Bool = false,
972969
decompression: Decompression = .disabled,
973-
http1_1ConnectionDebugInitializer:
974-
(@Sendable (Channel) -> EventLoopFuture<Void>)? = nil,
975-
http2ConnectionDebugInitializer:
976-
(@Sendable (Channel) -> EventLoopFuture<Void>)? = nil,
977-
http2StreamChannelDebugInitializer:
978-
(@Sendable (Channel) -> EventLoopFuture<Void>)? = nil
970+
http1_1ConnectionDebugInitializer: (@Sendable (Channel) -> EventLoopFuture<Void>)? = nil,
971+
http2ConnectionDebugInitializer: (@Sendable (Channel) -> EventLoopFuture<Void>)? = nil,
972+
http2StreamChannelDebugInitializer: (@Sendable (Channel) -> EventLoopFuture<Void>)? = nil
979973
) {
980974
self.init(
981975
tlsConfiguration: tlsConfiguration,

0 commit comments

Comments
 (0)