Fixed autocomplete bug
This commit is contained in:
@@ -47,7 +47,7 @@ class ArtistController < ApplicationController
|
||||
return render :nothing => true if autocomplete.nil?
|
||||
suggestions = []
|
||||
autocomplete["response"]["docs"].each do |doc|
|
||||
suggestions << doc["artist"] unless suggestions.include?(doc["artist"])
|
||||
suggestions << doc["artist"] unless suggestions.include?(doc["artist"]) or doc["artist"].nil?
|
||||
end
|
||||
render :json => {
|
||||
:query => params[:query],
|
||||
|
||||
Reference in New Issue
Block a user