aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/request_controller.rb
diff options
context:
space:
mode:
authorRobin Houston <robin.houston@gmail.com>2012-01-11 17:16:13 +0000
committerRobin Houston <robin.houston@gmail.com>2012-01-11 17:16:13 +0000
commit883a720e0efbf44e198dffd8efcf65f8d219b08e (patch)
treeac18d2ab593fa91dfa1708fa290bb1a2662bdc8e /app/controllers/request_controller.rb
parentd734493ce3bcade2c6a819fc98f9b60c860c3fa7 (diff)
parentf098a984efacc9cb486991e9ea2da206cf853c6e (diff)
Merge branch 'release/0.5' into develop
Diffstat (limited to 'app/controllers/request_controller.rb')
-rw-r--r--app/controllers/request_controller.rb8
1 files changed, 1 insertions, 7 deletions
diff --git a/app/controllers/request_controller.rb b/app/controllers/request_controller.rb
index f3bbd6708..6e33fe043 100644
--- a/app/controllers/request_controller.rb
+++ b/app/controllers/request_controller.rb
@@ -755,13 +755,7 @@ class RequestController < ApplicationController
# Since acts_as_xapian doesn't support the Partial match flag, we work around it
# by making the last work a wildcard, which is quite the same
query = params[:q]
- query = query.split(' ')
- if query.last.nil? || query.last.strip.length < 3
- @xapian_requests = nil
- else
- query = query.join(' OR ') # XXX: HACK for OR instead of default AND!
- @xapian_requests = perform_search([InfoRequestEvent], query, 'relevant', 'request_collapse', 5)
- end
+ @xapian_requests = perform_search_typeahead(query, InfoRequestEvent)
render :partial => "request/search_ahead.rhtml"
end