This commit is contained in:
Connor Johnstone
2026-03-24 12:57:12 -04:00
parent cb63619610
commit 827944170a
+2 -5
View File
@@ -302,15 +302,12 @@ async fn add_track_inner(
user_id: Option<i32>,
) -> WatchResult<bool> {
// Skip if a wanted_item with this recording MBID already exists
if let Some(mbid) = recording_mbid {
if queries::wanted::find_by_mbid(conn, mbid)
.await?
.is_some()
if let Some(mbid) = recording_mbid
&& queries::wanted::find_by_mbid(conn, mbid).await?.is_some()
{
tracing::debug!(title = title, mbid = mbid, "already in watchlist, skipping");
return Ok(false);
}
}
let artist = queries::artists::upsert(conn, artist_name, artist_mbid).await?;
let is_owned = matching::track_is_owned(conn, artist_name, title).await?;