class Sinatra::Request::AcceptEntry

def priority

def priority
  # We sort in descending order; better matches should be higher.
  [ @q, -@type.count('*'), @params.size ]
end