Skip to content

Commit d9540c0

Browse files
Commit via running ake Sources/repos
1 parent 2d605db commit d9540c0

File tree

2 files changed

+111
-419
lines changed

2 files changed

+111
-419
lines changed

Sources/repos/Client.swift

Lines changed: 7 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -4575,10 +4575,8 @@ public struct Client: APIProtocol {
45754575
)
45764576
let body: OpenAPIRuntime.HTTPBody?
45774577
switch input.body {
4578-
case .none:
4579-
body = nil
45804578
case let .json(value):
4581-
body = try converter.setOptionalRequestBodyAsJSON(
4579+
body = try converter.setRequiredRequestBodyAsJSON(
45824580
value,
45834581
headerFields: &request.headerFields,
45844582
contentType: "application/json; charset=utf-8"
@@ -4676,10 +4674,8 @@ public struct Client: APIProtocol {
46764674
)
46774675
let body: OpenAPIRuntime.HTTPBody?
46784676
switch input.body {
4679-
case .none:
4680-
body = nil
46814677
case let .json(value):
4682-
body = try converter.setOptionalRequestBodyAsJSON(
4678+
body = try converter.setRequiredRequestBodyAsJSON(
46834679
value,
46844680
headerFields: &request.headerFields,
46854681
contentType: "application/json; charset=utf-8"
@@ -4777,10 +4773,8 @@ public struct Client: APIProtocol {
47774773
)
47784774
let body: OpenAPIRuntime.HTTPBody?
47794775
switch input.body {
4780-
case .none:
4781-
body = nil
47824776
case let .json(value):
4783-
body = try converter.setOptionalRequestBodyAsJSON(
4777+
body = try converter.setRequiredRequestBodyAsJSON(
47844778
value,
47854779
headerFields: &request.headerFields,
47864780
contentType: "application/json; charset=utf-8"
@@ -5365,10 +5359,8 @@ public struct Client: APIProtocol {
53655359
)
53665360
let body: OpenAPIRuntime.HTTPBody?
53675361
switch input.body {
5368-
case .none:
5369-
body = nil
53705362
case let .json(value):
5371-
body = try converter.setOptionalRequestBodyAsJSON(
5363+
body = try converter.setRequiredRequestBodyAsJSON(
53725364
value,
53735365
headerFields: &request.headerFields,
53745366
contentType: "application/json; charset=utf-8"
@@ -5470,10 +5462,8 @@ public struct Client: APIProtocol {
54705462
)
54715463
let body: OpenAPIRuntime.HTTPBody?
54725464
switch input.body {
5473-
case .none:
5474-
body = nil
54755465
case let .json(value):
5476-
body = try converter.setOptionalRequestBodyAsJSON(
5466+
body = try converter.setRequiredRequestBodyAsJSON(
54775467
value,
54785468
headerFields: &request.headerFields,
54795469
contentType: "application/json; charset=utf-8"
@@ -5575,10 +5565,8 @@ public struct Client: APIProtocol {
55755565
)
55765566
let body: OpenAPIRuntime.HTTPBody?
55775567
switch input.body {
5578-
case .none:
5579-
body = nil
55805568
case let .json(value):
5581-
body = try converter.setOptionalRequestBodyAsJSON(
5569+
body = try converter.setRequiredRequestBodyAsJSON(
55825570
value,
55835571
headerFields: &request.headerFields,
55845572
contentType: "application/json; charset=utf-8"
@@ -8255,8 +8243,7 @@ public struct Client: APIProtocol {
82558243
let chosenContentType = try converter.bestContentType(
82568244
received: contentType,
82578245
options: [
8258-
"application/vnd.github.object",
8259-
"application/json"
8246+
"application/vnd.github.object"
82608247
]
82618248
)
82628249
switch chosenContentType {
@@ -8268,14 +8255,6 @@ public struct Client: APIProtocol {
82688255
.application_vnd_period_github_period_object(value)
82698256
}
82708257
)
8271-
case "application/json":
8272-
body = try await converter.getResponseBodyAsJSON(
8273-
Operations.repos_sol_get_hyphen_content.Output.Ok.Body.jsonPayload.self,
8274-
from: responseBody,
8275-
transforming: { value in
8276-
.json(value)
8277-
}
8278-
)
82798258
default:
82808259
preconditionFailure("bestContentType chose an invalid content type.")
82818260
}

0 commit comments

Comments
 (0)