Artist search encode fix
This commit is contained in:
parent
36eeafe71f
commit
1792125912
|
@ -44,7 +44,7 @@ module MusicBrainz
|
|||
def self.search name
|
||||
artists = []
|
||||
xml = Nokogiri::XML(MusicBrainz.load(
|
||||
'http://musicbrainz.org/ws/2/artist/?query='+ URI.escape(name).gsub(/\&/, '%26').gsub(/\?/, '%3F') +'~&limit=50'
|
||||
'http://musicbrainz.org/ws/2/artist/?query='+ CGI.escape(name).gsub(/\!/, '') +'~&limit=50'
|
||||
))
|
||||
xml.css('artist-list > artist').each do |a|
|
||||
artist = {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
require "open-uri"
|
||||
require "socket"
|
||||
require "nokogiri"
|
||||
require "cgi"
|
||||
|
||||
require "models/music_brainz"
|
||||
require "models/music_brainz/artist"
|
||||
|
|
Loading…
Reference in New Issue