diff --git a/src/search/indexing/local_import.rs b/src/search/indexing/local_import.rs index 85a5906e4..b8ea26ad6 100644 --- a/src/search/indexing/local_import.rs +++ b/src/search/indexing/local_import.rs @@ -163,8 +163,8 @@ pub async fn index_local(pool: PgPool) -> Result, IndexingE modified_timestamp: mod_data.updated.timestamp(), latest_version, license: Some(license.short), - client_side: client_side.to_string(), - server_side: server_side.to_string(), + client_side: Some(client_side.to_string()), + server_side: Some(server_side.to_string()), host: Cow::Borrowed("modrinth"), slug: mod_data.slug, }); @@ -312,8 +312,8 @@ pub async fn query_one( modified_timestamp: mod_data.updated.timestamp(), latest_version, license: Some(license.short), - client_side: client_side.to_string(), - server_side: server_side.to_string(), + client_side: Some(client_side.to_string()), + server_side: Some(server_side.to_string()), host: Cow::Borrowed("modrinth"), slug: mod_data.slug, }) diff --git a/src/search/mod.rs b/src/search/mod.rs index 1096474db..11a19f98e 100644 --- a/src/search/mod.rs +++ b/src/search/mod.rs @@ -75,8 +75,8 @@ pub struct UploadSearchMod { pub author_url: String, pub latest_version: Cow<'static, str>, pub license: Option, - pub client_side: String, - pub server_side: String, + pub client_side: Option, + pub server_side: Option, /// RFC 3339 formatted creation date of the mod pub date_created: DateTime, @@ -118,8 +118,8 @@ pub struct ResultSearchMod { pub date_modified: String, pub latest_version: String, pub license: Option, - pub client_side: String, - pub server_side: String, + pub client_side: Option, + pub server_side: Option, /// The host of the mod: Either `modrinth` or `curseforge` pub host: String,