Update autocomplete.rb

fix except logic