Resolve library import edge case

When adding a library, it is possible the single space character (' ') is added as an artist. The Musicbrainz function _do_mb_search is not capable of handling this, and throws a ValueError, as no query is provided. This checks if an artist fits this situation, and continues with the next possible artist.
This commit is contained in:
Ichabond
2012-08-30 14:50:41 +02:00
parent 87c9ebca28
commit 95e7c3c6b7

View File

@@ -41,7 +41,7 @@ def artistlist_to_mbids(artistlist, forced=False):
for artist in artistlist:
if not artist:
if not artist and not (artist == ' '):
continue
results = mb.findArtist(artist, limit=1)