X-Git-Url: https://git.kaliko.me/?a=blobdiff_plain;f=sima%2Fmpdclient.py;h=92ca0ceee21e1ec92a3d1450652047a8da3b4eec;hb=12d710d35febb030442322df99d851ad2da29704;hp=0883b009e8f45826226f66694f9c7b3ba754a634;hpb=4ce63ab3966acacc48c3b05be167af441a2a087c;p=mpd-sima.git diff --git a/sima/mpdclient.py b/sima/mpdclient.py index 0883b00..92ca0ce 100644 --- a/sima/mpdclient.py +++ b/sima/mpdclient.py @@ -517,6 +517,8 @@ class MPD(MPDClient): candidates = [] for album in albums: album_trks = self.find_tracks(album) + if not album_trks: # find_track result can be empty, blocklist applied + continue album_artists = {tr.albumartist for tr in album_trks if tr.albumartist} if album.Artist.names & album_artists: candidates.append(album) @@ -548,9 +550,6 @@ class MPD(MPDClient): self.log.debug('"%s" probably not an album of "%s" (ratio=%.2f)', album, artist, ratio) continue - for alb in albums: - if self.database.get_bl_album(album, add=False): - candidates.remove(album) return candidates # #### / Search Methods ###