summaryrefslogtreecommitdiff
path: root/nephilim/plugins/Lyrics.py
diff options
context:
space:
mode:
authorAnton Khirnov <wyskas@gmail.com>2009-05-05 20:30:29 +0200
committerAnton Khirnov <wyskas@gmail.com>2009-05-05 20:30:29 +0200
commit757c3855f0cbd9fb30dea733433d7701830488f4 (patch)
treedec6a020afaef1bc0553bf184e76cdb45b1252d3 /nephilim/plugins/Lyrics.py
parent369d3dbed4c8ee6a62f41d23361961542ced3240 (diff)
Lyrics: make utf-8 requests work with LyricWiki.
Diffstat (limited to 'nephilim/plugins/Lyrics.py')
-rw-r--r--nephilim/plugins/Lyrics.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/nephilim/plugins/Lyrics.py b/nephilim/plugins/Lyrics.py
index 29795f2..4a551e9 100644
--- a/nephilim/plugins/Lyrics.py
+++ b/nephilim/plugins/Lyrics.py
@@ -107,8 +107,8 @@ class Lyrics(Plugin):
def fetch_lyricwiki(self, song):
soap = LyricWiki_client.LyricWikiBindingSOAP("http://lyricwiki.org/server.php")
req = LyricWiki_client.getSongRequest()
- req.Artist = song.artist()
- req.Song = song.title()
+ req.Artist = song.artist().encode('utf-8').decode('iso8859').encode('utf-8')
+ req.Song = song.title().encode('utf-8').decode('iso8859').encode('utf-8')
try:
result = soap.getSong(req).Return.Lyrics.decode('utf-8').encode('iso8859').decode('utf-8')
except socket.error, e: