Ignore Artist fix

Fixes https://github.com/rembo10/headphones/issues/1660
This commit is contained in:
Ade
2014-08-16 10:49:42 +12:00
parent fc1c26f58f
commit 06822e2514

View File

@@ -299,8 +299,8 @@ class WebInterface(object):
if action == "ignore":
myDB = db.DBConnection()
for artist in args:
myDB.action('DELETE FROM newartists WHERE ArtistName=?', [artist])
myDB.action('UPDATE have SET Matched="Ignored" WHERE ArtistName=?', [artist])
myDB.action('DELETE FROM newartists WHERE ArtistName=?', [artist.decode(headphones.SYS_ENCODING, 'replace')])
myDB.action('UPDATE have SET Matched="Ignored" WHERE ArtistName=?', [artist.decode(headphones.SYS_ENCODING, 'replace')])
logger.info("Artist %s removed from new artist list and set to ignored" % artist)
raise cherrypy.HTTPRedirect("home")
addArtists.exposed = True