diff --git a/src/library.rs b/src/library.rs index 2c7933a..8bfc6ac 100644 --- a/src/library.rs +++ b/src/library.rs @@ -356,7 +356,7 @@ pub async fn add_track( async fn finish_add_track( conn: &DatabaseConnection, title: &str, - artist_name: &str, + _artist_name: &str, recording_mbid: Option, artist: artist::Model, user_id: Option, @@ -513,10 +513,10 @@ async fn load_or_build_discography( } // Cache the result if we found anything - if !recordings.is_empty() { - if let Ok(json) = serde_json::to_string(&recordings) { - let _ = queries::cache::set(conn, &cache_key, "computed", &json, 7 * 86400).await; - } + if !recordings.is_empty() + && let Ok(json) = serde_json::to_string(&recordings) + { + let _ = queries::cache::set(conn, &cache_key, "computed", &json, 7 * 86400).await; } recordings