diff options
author | fxqnlr <[email protected]> | 2023-02-05 09:23:29 +0100 |
---|---|---|
committer | fxqnlr <[email protected]> | 2023-02-05 09:23:29 +0100 |
commit | ff23a11e632812b685f594324e6004c6da81cd4d (patch) | |
tree | 2b503cb25d8ebfbc33d449860e1903a4c6c9513f /src/apis | |
parent | 2f4b5f1584f88491ea4a6902d69382a0e73aa76d (diff) | |
download | modlist-ff23a11e632812b685f594324e6004c6da81cd4d.tar modlist-ff23a11e632812b685f594324e6004c6da81cd4d.tar.gz modlist-ff23a11e632812b685f594324e6004c6da81cd4d.zip |
Fixed update shit not correctly updating
Diffstat (limited to 'src/apis')
-rw-r--r-- | src/apis/modrinth.rs | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/apis/modrinth.rs b/src/apis/modrinth.rs index 36ab5df..f3f89a7 100644 --- a/src/apis/modrinth.rs +++ b/src/apis/modrinth.rs | |||
@@ -63,9 +63,7 @@ pub enum Type { | |||
63 | pub enum Status { | 63 | pub enum Status { |
64 | approved, | 64 | approved, |
65 | rejected, | 65 | rejected, |
66 | draft, | 66 | draft, unlisted, archived, |
67 | unlisted, | ||
68 | archived, | ||
69 | processing, | 67 | processing, |
70 | unknown | 68 | unknown |
71 | } | 69 | } |
@@ -141,7 +139,6 @@ pub async fn project(api: String, name: &str) -> Project { | |||
141 | } | 139 | } |
142 | 140 | ||
143 | pub async fn projects(api: String, ids: Vec<String>) -> Vec<Project> { | 141 | pub async fn projects(api: String, ids: Vec<String>) -> Vec<Project> { |
144 | println!("\tGet versions from modrinth\n"); | ||
145 | let all = ids.join(r#"",""#); | 142 | let all = ids.join(r#"",""#); |
146 | let url = format!(r#"projects?ids=["{}"]"#, all); | 143 | let url = format!(r#"projects?ids=["{}"]"#, all); |
147 | 144 | ||
@@ -187,7 +184,6 @@ pub fn extract_current_version(versions: Vec<Version>) -> MLE<String> { | |||
187 | } | 184 | } |
188 | times.sort_by_key(|t| t.1); | 185 | times.sort_by_key(|t| t.1); |
189 | times.reverse(); | 186 | times.reverse(); |
190 | println!("\t └New current version: {}", times[0].0); | ||
191 | Ok(times[0].0.to_string()) | 187 | Ok(times[0].0.to_string()) |
192 | }, | 188 | }, |
193 | _ => panic!("available_versions should never be negative"), | 189 | _ => panic!("available_versions should never be negative"), |