module ThinkingSphinx::ActionController

Protected Instance Methods

append_info_to_payload(payload) click to toggle source
# File lib/thinking_sphinx/action_controller.rb, line 18
def append_info_to_payload(payload)
  super
  payload[:query_runtime] = query_runtime
end
cleanup_view_runtime() click to toggle source
# File lib/thinking_sphinx/action_controller.rb, line 9
def cleanup_view_runtime
  log_subscriber = ThinkingSphinx::ActiveRecord::LogSubscriber
  query_runtime_pre_render = log_subscriber.reset_runtime
  runtime = super
  query_runtime_post_render = log_subscriber.reset_runtime
  self.query_runtime = query_runtime_pre_render + query_runtime_post_render
  runtime - query_runtime_post_render
end