Skip to content

Commit d83d0ad

Browse files
committed
Remove required initializer for ServerAPI
1 parent 4cb8255 commit d83d0ad

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

Sources/ComposableArchitecturePattern/Server+API.swift

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,6 @@ public protocol ServerAPI: Identifiable, Equatable {
2121
/// For example, perhaps the server is using a specific environment but this API uses a different environment for some other purpose, such as a specific authentication endpoint. Setting this to `true` would mean that the API will throw an error if the environments don't match up.
2222
var strictEnvironmentEnforcement: Bool { get }
2323

24-
/// Initialize with the provided values.
25-
///
26-
/// - Note: It is highly encouraged to define your `supportedReturnObjects` to ensure `-supports<T: Codable>(_:)` is able to automatically verify against this.
27-
init(environment: ServerEnvironment?, path: String, headers: [String: String]?, queries: [URLQueryItem]?, supportedHTTPMethods: [HTTPMethod], supportedReturnObjects: [Codable.Type]?, timeoutInterval: TimeInterval)
28-
2924
func request(_ method: HTTPMethod, in environment: ServerEnvironment?, additionalHeaders: [String: String]?, additionalQueries: [URLQueryItem]?, httpBodyOverride httpBody: Data?, timeoutInterval: TimeInterval?) throws -> URLRequest
3025

3126
/// Whether or not the provided type is supported by the API. Defaults to checking if the type is found in `supportedReturnObjects` or returning `false` if not found.

0 commit comments

Comments
 (0)