From 60222936c294241abc87ed30b0653e399d25364d Mon Sep 17 00:00:00 2001 From: Philip Date: Tue, 28 Sep 2021 21:46:43 +0200 Subject: [PATCH 1/2] Update steam_shortcuts_util version --- Cargo.lock | 4 ++-- Cargo.toml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 44acbec..bc03c9e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1102,9 +1102,9 @@ dependencies = [ [[package]] name = "steam_shortcuts_util" -version = "1.1.2" +version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51eecf84626e7ba46667be999ca124d9cd16c9feb09918dd991eccbb4ac298e7" +checksum = "66ae244ca0579ba5b4e05a52a3afef6f23412e85b8eb448dbf0aa92d0687cb50" dependencies = [ "ascii", "crc32fast", diff --git a/Cargo.toml b/Cargo.toml index 5a601e4..fd88dde 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -5,7 +5,7 @@ edition = "2018" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -steam_shortcuts_util = "1.1.2" +steam_shortcuts_util = "1.1.4" steamgriddb_api = "0.2,0" serde = { version = "1.0.130", features = ["derive"] } serde_json = "1.0.68" From 1924afd197de899a07a1c6c8cd6dc8bc03a4e69e Mon Sep 17 00:00:00 2001 From: Philip Date: Tue, 28 Sep 2021 21:50:25 +0200 Subject: [PATCH 2/2] Only print searching when cache miss searching --- src/steamgriddb/cached_search.rs | 2 +- src/steamgriddb/downloader.rs | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/steamgriddb/cached_search.rs b/src/steamgriddb/cached_search.rs index abd63e9..e51e1ff 100644 --- a/src/steamgriddb/cached_search.rs +++ b/src/steamgriddb/cached_search.rs @@ -28,7 +28,7 @@ impl<'a> CachedSearch<'a> { if let Some(result) = cached_result { return Ok(Some(result.1)); } - + println!("Searching for {}", query); let search = self.client.search(query).await?; if search.is_empty() { return Ok(None); diff --git a/src/steamgriddb/downloader.rs b/src/steamgriddb/downloader.rs index 361d949..adb0e6c 100644 --- a/src/steamgriddb/downloader.rs +++ b/src/steamgriddb/downloader.rs @@ -30,8 +30,7 @@ pub async fn download_images<'a, 'b>( return Ok(()); } let mut search_results = HashMap::new(); - for s in shortcuts_to_search_for { - println!("Searching for {}", s.app_name); + for s in shortcuts_to_search_for { let search = search.search(s.app_id, s.app_name).await?; if let Some(search) = search { search_results.insert(s.app_id, search);