Skip to content

Commit

Permalink
update to OpenAPIKit v1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
mattpolzin committed May 14, 2020
1 parent b40c82e commit 34eb557
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 13 deletions.
12 changes: 6 additions & 6 deletions Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@
},
{
"package": "OpenAPIKit",
"repositoryURL": "https://github.com/mattpolzin/OpenAPIKit.git",
"repositoryURL": "https://github.com/mattpolzin/OpenAPIKit",
"state": {
"branch": null,
"revision": "5c18f9c57617d8b0232a50fcfd1568e4f1d1da6c",
"version": "0.30.1"
"revision": "732251ae2eb1965c9323ae4f8024df908979b7cf",
"version": "1.0.1"
}
},
{
Expand All @@ -30,7 +30,7 @@
},
{
"package": "Sampleable",
"repositoryURL": "https://github.com/mattpolzin/Sampleable.git",
"repositoryURL": "https://github.com/mattpolzin/Sampleable",
"state": {
"branch": null,
"revision": "df44bf1a860481109dcf455e3c6daf0a0f1bc259",
Expand All @@ -42,8 +42,8 @@
"repositoryURL": "https://github.com/jpsim/Yams.git",
"state": {
"branch": null,
"revision": "c947a306d2e80ecb2c0859047b35c73b8e1ca27f",
"version": "2.0.0"
"revision": "81a65c4069c28011ee432f2858ba0de49b086677",
"version": "3.0.1"
}
}
]
Expand Down
4 changes: 2 additions & 2 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ let package = Package(
targets: ["OpenAPIReflection"]),
],
dependencies: [
.package(url: "https://github.com/mattpolzin/OpenAPIKit.git", .upToNextMinor(from: "0.30.0")),
.package(url: "https://github.com/mattpolzin/Sampleable.git", .upToNextMajor(from: "2.1.0"))
.package(url: "https://github.com/mattpolzin/OpenAPIKit", from: "1.0.0"),
.package(url: "https://github.com/mattpolzin/Sampleable", from: "2.1.0")
],
targets: [
.target(
Expand Down
2 changes: 1 addition & 1 deletion Sources/OpenAPIReflection/OpenAPI+Errors.swift
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//
// File.swift
// OpenAPI+Errors.swift
//
//
// Created by Mathew Polzin on 4/21/20.
Expand Down
4 changes: 1 addition & 3 deletions Sources/OpenAPIReflection/Sampleable+OpenAPI.swift
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,7 @@ public func genericOpenAPISchemaGuess<T>(for value: T, using encoder: JSONEncode
// fail to the newer value arbitrarily
let propertiesDict = Dictionary(properties) { _, value2 in value2 }

return .object(.init(format: .generic,
required: true),
.init(properties: propertiesDict))
return .object(required: true, properties: propertiesDict)
}

/// Same as genericOpenAPISchemaGuess() except it checks if there's an easy
Expand Down
2 changes: 1 addition & 1 deletion Sources/OpenAPIReflection/SchemaProtocols.swift
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//
// File.swift
// SchemaProtocols.swift
//
//
// Created by Mathew Polzin on 3/4/20.
Expand Down

0 comments on commit 34eb557

Please sign in to comment.