From: Alexander Yakushev Date: Wed, 4 Jan 2012 12:29:23 +0000 (+0200) Subject: Remove escaped slashes from song and artist names X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;h=b03ada4a0d3a71a51af0f68082e53df07d4c72bf;p=awesompd.git Remove escaped slashes from song and artist names Since Jamendo started for some reason escaping slashes with backslashes in their API output (so slashes become like this \/) one bug was already fixed, and now this cosmetic change is commited. --- diff --git a/jamendo.lua b/jamendo.lua index 4e2ca30..0f30b13 100644 --- a/jamendo.lua +++ b/jamendo.lua @@ -164,6 +164,11 @@ function return_track_table(request_table) end _, _, parse_table[i].artist_link_name = string.find(parse_table[i].artist_url, "\\/artist\\/(.+)") + -- Remove Jamendo escape slashes + parse_table[i].artist_name = + string.gsub(parse_table[i].artist_name, "\\/", "/") + parse_table[i].name = string.gsub(parse_table[i].name, "\\/", "/") + parse_table[i].display_name = parse_table[i].artist_name .. " - " .. parse_table[i].name -- Do Jamendo a favor, extract album_id for the track yourself