Skip to content

Commit 257f0b7

Browse files
committed
PR feedback, use the word import
1 parent 30379cd commit 257f0b7

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Sources/_OpenAPIGeneratorCore/Translator/CommonTypes/Constants.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import OpenAPIKit
1818
enum Constants {
1919

2020
/// Constants related to the library dependencies.
21-
enum Dependency {
21+
enum Import {
2222

2323
/// The module name of the OpenAPI runtime library.
2424
static let runtime: String = "OpenAPIRuntime"
@@ -35,7 +35,7 @@ enum Constants {
3535

3636
/// The descriptions of modules imported by every generated file.
3737
static let imports: [ImportDescription] = [
38-
ImportDescription(moduleName: Constants.Dependency.runtime, spi: "Generated"),
38+
ImportDescription(moduleName: Constants.Import.runtime, spi: "Generated"),
3939
ImportDescription(
4040
moduleName: "Foundation",
4141
moduleTypes: ["struct Foundation.URL", "struct Foundation.Data", "struct Foundation.Date"],
@@ -45,7 +45,7 @@ enum Constants {
4545

4646
/// The descriptions of modules imported by client and server files.
4747
static let clientServerImports: [ImportDescription] =
48-
imports + [ImportDescription(moduleName: Constants.Dependency.httpTypes)]
48+
imports + [ImportDescription(moduleName: Constants.Import.httpTypes)]
4949
}
5050

5151
/// Constants related to the OpenAPI server object.

Sources/_OpenAPIGeneratorCore/Translator/TypeAssignment/Builtins.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,14 @@ extension TypeName {
3636
/// OpenAPIRuntime module.
3737
/// - Parameter name: The name of the type.
3838
/// - Returns: A TypeName representing the specified type within the OpenAPIRuntime module.
39-
static func runtime(_ name: String) -> TypeName { TypeName(swiftKeyPath: [Constants.Dependency.runtime, name]) }
39+
static func runtime(_ name: String) -> TypeName { TypeName(swiftKeyPath: [Constants.Import.runtime, name]) }
4040

4141
/// Returns a type name for a type with the specified name in the
4242
/// HTTPTypes module.
4343
/// - Parameter name: The name of the type.
4444
/// - Returns: A TypeName representing the type with the given name in the HTTPTypes module.
4545
static func httpTypes(_ name: String) -> TypeName {
46-
TypeName(swiftKeyPath: [Constants.Dependency.httpTypes, name])
46+
TypeName(swiftKeyPath: [Constants.Import.httpTypes, name])
4747
}
4848

4949
/// Returns the type name for the Date type.

0 commit comments

Comments
 (0)