aboutsummaryrefslogtreecommitdiff
path: root/src-tauri/src
diff options
context:
space:
mode:
Diffstat (limited to 'src-tauri/src')
-rw-r--r--src-tauri/src/lib.rs6
-rw-r--r--src-tauri/src/main.rs2
-rw-r--r--src-tauri/src/mod_management/mod.rs6
3 files changed, 6 insertions, 8 deletions
diff --git a/src-tauri/src/lib.rs b/src-tauri/src/lib.rs
index e43e5935..1ae55a6f 100644
--- a/src-tauri/src/lib.rs
+++ b/src-tauri/src/lib.rs
@@ -192,9 +192,7 @@ async fn do_install(nmod: &thermite::model::ModVersion, game_path: &std::path::P
let download_path = format!("{}/{}", download_directory.clone(), filename);
println!("{}", download_path);
- let nfile = thermite::core::manage::download_file(&nmod.url, download_path)
- .await
- .unwrap();
+ let nfile = thermite::core::manage::download_file(&nmod.url, download_path).unwrap();
println!("Extracting Northstar...");
extract(nfile, game_path)?;
@@ -223,7 +221,7 @@ pub async fn install_northstar(
None => "Northstar".to_string(),
};
- let index = thermite::api::get_package_index().await.unwrap().to_vec();
+ let index = thermite::api::get_package_index().unwrap().to_vec();
let nmod = index
.iter()
.find(|f| f.name.to_lowercase() == northstar_package_name.to_lowercase())
diff --git a/src-tauri/src/main.rs b/src-tauri/src/main.rs
index 4eab7a00..ba9264ee 100644
--- a/src-tauri/src/main.rs
+++ b/src-tauri/src/main.rs
@@ -185,7 +185,7 @@ async fn check_is_northstar_outdated(
None => "Northstar".to_string(),
};
- let index = thermite::api::get_package_index().await.unwrap().to_vec();
+ let index = thermite::api::get_package_index().unwrap().to_vec();
let nmod = index
.iter()
.find(|f| f.name.to_lowercase() == northstar_package_name.to_lowercase())
diff --git a/src-tauri/src/mod_management/mod.rs b/src-tauri/src/mod_management/mod.rs
index 01e2cbb5..90dc85da 100644
--- a/src-tauri/src/mod_management/mod.rs
+++ b/src-tauri/src/mod_management/mod.rs
@@ -261,7 +261,7 @@ pub fn get_installed_mods_and_properties(
async fn get_ns_mod_download_url(thunderstore_mod_string: String) -> Result<String, String> {
// TODO: This will crash the thread if not internet connection exist. `match` should be used instead
- let index = thermite::api::get_package_index().await.unwrap().to_vec();
+ let index = thermite::api::get_package_index().unwrap().to_vec();
// Parse mod string
let parsed_ts_mod_string: ParsedThunderstoreModString = match thunderstore_mod_string.parse() {
@@ -297,7 +297,7 @@ async fn get_mod_dependencies(
dbg!(thunderstore_mod_string.clone());
// TODO: This will crash the thread if not internet connection exist. `match` should be used instead
- let index = thermite::api::get_package_index().await.unwrap().to_vec();
+ let index = thermite::api::get_package_index().unwrap().to_vec();
// String replace works but more care should be taken in the future
let ts_mod_string_url = thunderstore_mod_string.replace("-", "/");
@@ -379,7 +379,7 @@ pub async fn fc_download_mod_and_install(
);
// Download the mod
- let f = match thermite::core::manage::download_file(&download_url, path.clone()).await {
+ let f = match thermite::core::manage::download_file(&download_url, path.clone()) {
Ok(f) => f,
Err(e) => return Err(e.to_string()),
};