@@ -95,7 +95,7 @@ public extension Http{
95
95
query : Query ? = nil ,
96
96
headers : Headers ? = nil ,
97
97
retry : UInt = 1 ,
98
- validate : [ Http . Validate ] = [ . status( . const( 200 ) ) ] ,
98
+ validate : [ Http . Validate ] = [ . status( . const( ) ) ] , /// default 200
99
99
taskDelegate: ITaskDelegate ? = nil
100
100
) async throws
101
101
-> Http . Response < T > where T: Decodable
@@ -125,7 +125,7 @@ public extension Http{
125
125
query : Query ? = nil ,
126
126
headers : Headers ? = nil ,
127
127
retry : UInt = 1 ,
128
- validate : [ Http . Validate ] = [ . status( . const( 200 ) ) ] ,
128
+ validate : [ Http . Validate ] = [ . status( . const( ) ) ] , /// default 200
129
129
taskDelegate: ITaskDelegate ? = nil
130
130
) async throws
131
131
-> Http . Response < T > where T: Decodable
@@ -157,7 +157,7 @@ public extension Http{
157
157
query : Query ? = nil ,
158
158
headers : Headers ? = nil ,
159
159
retry : UInt = 1 ,
160
- validate : [ Http . Validate ] = [ . status( . range ( 200 ..< 300 ) ) ] ,
160
+ validate : [ Http . Validate ] = [ . status( . const ( ) ) ] , /// default 200
161
161
taskDelegate: ITaskDelegate ? = nil
162
162
) async throws
163
163
-> Http . Response < T > where T: Decodable
@@ -178,7 +178,7 @@ public extension Http{
178
178
public func send< T> (
179
179
with request : URLRequest ,
180
180
retry strategy : RetryService . Strategy = . exponential( ) ,
181
- _ validate : [ Http . Validate ] = [ . status( . const( 200 ) ) ] ,
181
+ _ validate : [ Http . Validate ] = [ . status( . const( ) ) ] , /// default 200
182
182
_ taskDelegate: ITaskDelegate ? = nil
183
183
) async throws -> Http . Response < T > where T : Decodable
184
184
{
0 commit comments