mirror of
https://github.com/SoongNoonien/mpdevil.git
synced 2023-08-10 21:12:44 +03:00
fixed cover loading error when no music dir is specified
This commit is contained in:
parent
2cd18d931f
commit
7e7d6c673f
@ -1394,8 +1394,8 @@ class Cover(object):
|
||||
lib_path=settings.get_value("paths")[active_profile]
|
||||
if lib_path == "":
|
||||
lib_path=GLib.get_user_special_dir(GLib.UserDirectory.DIRECTORY_MUSIC)
|
||||
if lib_path is not None:
|
||||
regex_str=settings.get_value("regex")[active_profile]
|
||||
|
||||
if regex_str == "":
|
||||
regex=re.compile(COVER_REGEX, flags=re.IGNORECASE)
|
||||
else:
|
||||
@ -1406,7 +1406,6 @@ class Cover(object):
|
||||
except:
|
||||
print("illegal regex:", regex_str)
|
||||
return
|
||||
|
||||
if song_file is not None:
|
||||
song_dir=os.path.join(lib_path, os.path.dirname(song_file))
|
||||
if song_dir.endswith(".cue"):
|
||||
|
Loading…
Reference in New Issue
Block a user