From 7415b07586fe9626c10886f8b7ce3620b7847cdc Mon Sep 17 00:00:00 2001 From: "Emma C. Pointer-Null" Date: Thu, 24 Mar 2022 22:58:07 -0400 Subject: [PATCH] Add more version creation data aliases (#325) For consistency and also for making the OpenAPI spec a bit less janky --- src/routes/version_creation.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/routes/version_creation.rs b/src/routes/version_creation.rs index 6d30b3c0..a3facbda 100644 --- a/src/routes/version_creation.rs +++ b/src/routes/version_creation.rs @@ -34,8 +34,10 @@ pub struct InitialVersionData { )] pub version_number: String, #[validate(length(min = 3, max = 256))] + #[serde(alias = "name")] pub version_title: String, #[validate(length(max = 65536))] + #[serde(alias = "changelog")] pub version_body: Option, #[validate( length(min = 0, max = 256), @@ -44,6 +46,7 @@ pub struct InitialVersionData { pub dependencies: Vec, #[validate(length(min = 1))] pub game_versions: Vec, + #[serde(alias = "version_type")] pub release_channel: VersionType, #[validate(length(min = 1))] pub loaders: Vec,