discourse/app/controllers/search_controller.rb
Sam b6bf95e741 speed up startup (avoid loading some gems on startup)
correct group permission leaks
add Discourse.cache for richer caching support
2013-05-13 18:04:03 +10:00

11 lines
260 B
Ruby

require_dependency 'search'
class SearchController < ApplicationController
def query
search_result = Search.query(params[:term], guardian, params[:type_filter], SiteSetting.min_search_term_length)
render_json_dump(search_result.as_json)
end
end