We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 09f8ba3 commit b286827Copy full SHA for b286827
src/types/mod_json.rs
@@ -26,7 +26,8 @@ pub struct ModJson {
26
pub version: String,
27
pub id: String,
28
pub name: String,
29
- pub developer: String,
+ pub developer: Option<String>,
30
+ pub developers: Option<Vec<String>>,
31
pub description: Option<String>,
32
pub repository: Option<String>,
33
pub issues: Option<serde_json::Value>,
@@ -354,6 +355,12 @@ impl ModJson {
354
355
)));
356
}
357
358
+ if self.developer.is_none() && self.developers.is_none() {
359
+ return Err(ApiError::BadRequest(
360
+ "No developer specified on mod.json".to_string(),
361
+ ));
362
+ }
363
+
364
if self.id.len() > 64 {
365
return Err(ApiError::BadRequest(
366
"Mod id too long (max 64 characters)".to_string(),
0 commit comments