Lyrics generic get_attrs

It can be used here too!
This commit is contained in:
Bryan Schumaker 2010-12-07 08:17:56 -05:00
parent 9f7e838ec2
commit 0722045bdb

View File

@ -78,8 +78,7 @@ def fetch_lyrics(file, artist, title):
return True
def set_lyrics(filepath):
id = libsaria.path.file_id(filepath)
artist, title = libsaria.sources.library.get_attrs(id, "artist", "title")
artist, title = libsaria.sources.get_attrs("artist", "title")
cached = cache[artist]
file = cached.get("%s.txt" % title, fetch_lyrics, artist, title)
if file != None: