]> kaliko git repositories - mpd-sima.git/blobdiff - sima/lib/webserv.py
Fixed regression introduced with 8870413
[mpd-sima.git] / sima / lib / webserv.py
index 734a5f0b40a39b4e895ebc277f2a73691265aaab..1f75c2000235919dd49c093be9f1a0c8bfa4ccbc 100644 (file)
@@ -303,7 +303,9 @@ class WebService(Plugin):
         """Retrieve album history"""
         albums_list = set()
         for trk in self.get_history(artist=artist.name):
-            albums_list.add(trk[1])
+            if not trk.album:
+                continue
+            albums_list.add(trk.album)
         return albums_list
 
     def find_album(self, artists):
@@ -370,6 +372,7 @@ class WebService(Plugin):
                 titles = [t for t in self.ws.get_toptrack(artist)]
             except WSError as err:
                 self.log.warning('%s: %s', self.ws.name, err)
+                continue
             for trk in titles:
                 found = self.player.search_track(artist, trk.title)
                 if found: